cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Dual Super User
Dual Super User

Re: Help with new and edit forms

Hey @Donna_S 

 

Can you confirm if the "item" property of the form is set to LookUp(DataSource, EmployeeName = gallery1.Selected.DisplayName)?
 
To fetch the records from existing items, this property is used.
 
Also, can you create a temporary label and check on the Text property use the expression:
Text(Form1.Mode)
 
If this is 0, this meand the form is in edit mode and if it is 1 then the form mode is new. So, now can you check the form mode for the already created items? Please reply back with the results and we can debug this together.
 
Hope this Helps!
 
If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!
Highlighted
Regular Visitor

Re: Help with new and edit forms

Hi @yashag2255 

 

The item property of the form is LookUp('Manager Notes','Direct Report'.DisplayName=Gallery1_2.Selected.DisplayName)

 

Manager notes is the data source. Direct Reports is the column where the name would go.

 

I have added in the label which is showing as 1

 

Thanks

Donna

Highlighted
Dual Super User
Dual Super User

Re: Help with new and edit forms

Hey @Donna_S 

 

Since the label shows as 1, this means the form mode is New, but if the record already exists, then it should be in edit mode. 
 
Can you please confirm that the OnSelect property of the gallery is:
If(CountRows(Filter('Manager Notes','Direct Report'.DisplayName = Gallery1_1.Selected.DisplayName)) = 0,NewForm(Form1),EditForm(Form1))

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Highlighted
Regular Visitor

Re: Help with new and edit forms

Hi @yashag2255 ,

 

Yup that is correct, that is the same that is on my OnSelect property of the gallery.

 

Thanks

Donna

Helpful resources

Announcements
secondImage

Demo-Extravaganza 2020

Check out these cool Power Apps & vote on your favorite!

secondImage

Community Highlights

Check out whats happening in Power Apps

secondImage

Community User Group Member Badges

FIll out a quick form to claim your community user group member badge today!

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (7,831)