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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Change FormMode when n...
Power Apps
Unanswered

Change FormMode when no record is found in SharePoint for the signed in user

(0) ShareShare
ReportReport
Posted on by 2

I have a custom form that is currently in New mode.

I would like to update the existing item in the SharePoint list if a record was found for the signed in user.

Thus far in the DefaultMode property of the Form I have:

"If( CountRows('My Data Source'. 'Created By' = User().Email > 0, FormMode.Edit, FormMode.New)"

 

Please assist

Categories:
  • SkiDK Profile Picture
    1,016 on at

    Hi @KirwinM 

    You're practically there. Can you try it like this:

    If(CountRows(Filter('My Data Source', 'Created By' = User().Email)) > 0, FormMode.Edit, FormMode.New)

     

  • KirwinM Profile Picture
    2 on at

    Thank you. It seems to validate now.

    However, the Screen now displays, "No item to display", whether I have a record in the SharePoint List or I removed my record.

    Are there other properties to set?

  • Nogueira1306 Profile Picture
    7,390 Super User 2024 Season 1 on at

    Following @SkiDK , if you want to edit something, you have to say which one you want to edit. So, you have to insert a gallery to choose the item and a button to create a new one

  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at
    If(
     IsBlank(
     Lookup('My Data Source', 'Created By'.Email = User().Email
     ), FormMode.New,FormMode.Edit
    )

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 397 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 354

#3
WarrenBelz Profile Picture

WarrenBelz 232 Most Valuable Professional

Last 30 days Overall leaderboard