Hello.
I am using a custom Sharepoint form where the user will be uploading documents using the Attachment datacard. What i would like to happen is that when the user attaches the document, Powerapps would check to see if the attachment name already exists in another library. If the name already exists, the user would be given a warning.
I tried using variations of the following formula without success.
If(First(DataCardValue34.Attachments).Name in IC.Name, Notify("Name already exists in our database. Please choose a unique name for your IC document.", Error),Set(IsAttached, true))
I also tried creating a label and having the label equal the name of the document being attached. Taking that and comparing against the Name column in the IC library. Here is an example of one of the formulas that i used.
If(!IsBlank(LookUp(IC, Name = Label5.Text)), Notify("Name already exists in our database. Please choose a unique name for your IC document.", Error),Set(IsAttached, true))
I am at a loss and not sure where to go from here. Thank you for your help in advance.