I have created a gallery that when I go to the "Detail Form" it will allow me to see data in another forms as well. The Detail screen contains:
DetailForm1 - Gallery1 is the source for this form
Form2 -Event Data is the source for this form
Each form contains the same data field called Title.
I have used a LookUp function in Items of Form2 to pull data from its source if the data matches the data field from the Gallery textbox referred to as DataCardValue1. If their is data already in the Event Data source matching then Form2's mode is 'View'. I would like to change the mode to 'New' so I can add data to the file from Gallery1 on Form2 if it hasn't already been added.
The code I have written is the following:
If(LookUp('Event Data', DataCardValue1.Text = Title, Title), FormMode.View, If(!IsBlank(LookUp('Event Data', DataCardValue1.Text = Title, Title)), FormMode.New, FormMode.View), FormMode.New, FormMode.View).
I see a message that there is an error in the formula, describing it as there was an expected value compatible with 'DataSource'. I am not sure how to fix this error. Any suggestions?
Ange