web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Apps
Suggested Answer

Error in collect

(1) ShareShare
ReportReport
Posted on by
Hi, hope you are well and thanks for reading. 
I need help with a power apps form that is linked to my SHP list. I need that according to the mails that are stored in the Editors list of my ListA, certain fields are edit or read only. 
From what I researched I need to apply in DisplyMode the following configuration:
 If(
    User().Email in UserListWithEdit,
    DisplayMode.Edit,
    DisplayMode.View
)
But when I want to create as collection ListaDeUsuariosConEdicion I have problems because it does not recognize in the ONSTART the Collect nor the ClearColeect it tells me that a +, * or & operator was expected and the name ListaDeUsuariosConEdicion marks it as name not recognized. Someone is so kind to help me please.
Thanks for taking the time to read.
Regards,
Ana
Translated with DeepL.com (free version)
Categories:
I have the same question (0)
  • Suggested answer
    Michael E. Gernaey Profile Picture
    53,452 Super User 2025 Season 2 on at
    Hi
     
    You need to share that code that has the error please. I have some guesses, but its hard to tell you without seeing a screenshot of the error/code.
     
    Usually this happens, because you are doing a Collect/ClearCollect on something that hasn't been defined before, OR has been defined in other places and dooesn't match.
     
    So please share the code/OnStart please.
     
    Also try this,
     
    At the top of the AppOnStart. Before Any other Code, put ClearCollect(ListaDeUsuariosConEdicion , {});
     
     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 739 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard