I was checking a video from Shane Young
And he mentioned that is better to start replacing the onselect = Navigate.........
then in the target form items = VarRecord
Basically replacing Gallery1.selected.
He said that this method is better and secure.
Now my question is?
I did that and my target form is a form. After press to EDIT the form and save the changes the updates didn't come up. I have to go back select the item again and after that I can see the changes.
How can I fix this? I have tried Refresh etc but nothing works.
Thanks in advance,
Solved! Go to Solution.
Hi @sajarac ,
BrowseGallery1.selected will give you the selected record of the gallery however it will create the dependency of the previous screen when you move out of the screen so it is always a good idea to set the selected record to a variable and use that varaiable the following screen.
Again, there is nothing wrong but it will pull down the performance of the APP.
I hope this resolved your issue if you see any challenge/need further help please let me know I am always happy to do it for my community.
If this post helps you give a 👍 and if it solved your issue consider Accept it as the solution to help the other members find it more.
In the Item property of the edit form: Lookup(datasource, ID=VarRecord.ID) and make sure the datasource in the Form is the same one as referenced in the Item property.
I did the Lookup addendum, it seems like is working a little bit better just one thing is not working fine. In the form I have 3 Dropdowns they work in a cascade way. I noticed that those 3 are keeping the last information saved. But if I put the form in edit mode and cancel or save the it show the right value.
In the OnSuccess property of the form, put ResetForm(Form1). When the form is submitted successfuly, all of the controls on it will be reset to their default properties. As a alternative, you can reset each control individually using Reset(Dropdown1); Reset(Combobox1); Reset(Combobox2).
Hi @sajarac ,
Have you solved your problem?
Based on the issue that you mentioned, I think this issue is related to the varRecord variable. If you update the selected record using your Edit form, you should also update the varRecord variable to the updated record simultaneously, otherwise, this varRecord variable would still store previous record.
So please consider set the OnSuccess property of the Edit form to following:
Set(varRecord, EditForm1.LastSubmit) // update the varRecord variable to the updated record
Set the Item property of the EditForm1 to following:
Actually, it is not necessary to store the whole selected record into a variable, instead, you could consider save the PrimaryKey column value of the selected record into a variable. Please also consider try the following workaround:
Set the OnSelect property of the Gallery to following:
Set the Item property of the Edit form to following:
LookUp('Your Data Source', PrimaryKeyColumn = varPrimaryKey)
Please consider take a try with above solution, then check if the issue is solved.
Learn how to create your own user groups today!
Explore the latest tools,training sessions,technical expertise, networking and more.
Check out the new Power Platform Community Connections gallery!
Congratulations, the new Super User Season 2 for 2021 has started!
Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.