Hey Team,
I have created a form in power apps with AX as the back end. On the submit button I'm checking with my back end for duplicate entry if the entry is already present in my db then a popup for DuplicateENtry should be visible and if the record doesn't exists in the db it should submit the form and a SubmitPopUp should appear.The problem is every time I click the submit button even if the record already exists in the db it does not submit the form but I get only the submitPopUp and not the DuplicatePopUp.
My logic on submit button is:
If(EmailAddress.Text in EmployeePAs_1.Email,UpdateContext({DuplicatePopUp:true});ResetForm(Form2),SubmitForm(Form2);UpdateContext({SubmitPopup:true})) and I have the set the visibility for DuplicatePOpup group as "DuplicatePopUp" and for submitpopgroup as "SubmitPopup"
Please help me as what is wrong and why I get my duplicate entry popup when the record already exists.