0

I have created a Survey process for internal users. I set the field OptionsAllowGuestUserResponse = true to skip the login page that appears for Internal users when they try to give feedback. For this, the internal users don't have to log in to give feedback. But now the survey link is available for multiple survey attempts. Can anyone have any idea how to prevent the multiple survey attempt?

SurveyInvitation Sv = New SurveyInvitation();
Sv.CommunityId = NETWORKID;
Sv.Name = SURVEYNAME;
//Sv.ParticipantId = Cse.RelatedPerson__c;
Sv.OptionsCollectAnonymousResponse = false;
Sv.OptionsAllowGuestUserResponse = true;
Sv.SurveyId = surv.Id;
Sv.RecordTypeId = RECID;
Database.SaveResult result = DATABASE.INSERT(Sv);

1 Answer 1

0

I see that there is a support case logged for this issue for which the closing summary is that this feature is currently not in Salesforce roadmap. Related Idea ,similar post

Alternative: Create a checkbox on the case object to identify if the survey already has been submitted or not. With a process builder on the survey taker object upon creation, check if the previously created checkbox on the case is empty. If this is the case, update the checkbox to the value True. Create a validation rule on the Survey Taken object (Case__r.your_checkbox= True). Set the error location to the Survey object and the end user will see your message.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .