Hi all,
I’m trying to prevent users from submitting duplicate files in the attachment section.
I added the following logic in the OnAddFile property. It successfully detects duplicate files, but it does not remove the duplicate from the attachment control.
I would prefer not to use Reset(Self), since that would remove all files. Instead, I’d like to:
- remove only the duplicate file, or
- ensure that if the same file is uploaded multiple times, it only appears once in the attachments list.
{ newName: Lower(Last(Self.Attachments).Name) },
If(
CountIf(Self.Attachments As f, Lower(f.Name) = newName) > 1,
Notify("This file has already been uploaded.")
)
)

Report
All responses (
Answers (