I have an edit form on a Screen in my PowerApp that isn't displaying the data. It currently references "Gallery.Selected" which is the gallery where an item is selected that I want to edit. I've had this work fine in the past but in the latest PowerApp it doesn't want to work. To see if the data was transferring correctly I set a junk View Form on the same Screen and it displays the data fine with the same data source and same Item information. The only difference between the two seems to be "Edit" versus "View". If I set my Edit Form to View and back to Edit it starts displaying the data. When I switch pages and come back in play mode it doesn't show the data anymore. It is very confusing. I've changed how I reference the data multiple times. I've used the direct "Gallery.Selected" approach. I've also used the "Lookup(DataSource, ID = Gallery.Selected.ID)" approach. The data reference appears to be fine but the edit form simply doesn't want to display data. I wiped it and re-created it from scratch and still nothing.
Spoke to one of my colleagues and he recommended a band-aid solution which is working for me for now.
On my button that transitions to the Edit Form screen I define a global variable that I called "Fix" which is used in the Mode for the Form Edit. When I hit that button it changes the variable to FormMode.View and then back to FormMode.Edit right away. Now when I load that page all the data is displayed.
Baffling but it has solved the functional problem even though I don't like not knowing why I have to patch it like this.
Attached is the properties for my Edit Form.
My exact steps were Insert > Edit Form, pick my data source, pick my fields, and then manually set the Item to "Gallery_DWG.Selected". I've redone the process multiple times thinking that my customizing on the previous one might have "broken" something but no change in my results. My View form has the same data for DataSource and Item just obviously without the "DefaultMode" field.
Hi @Ididar ,
View Form is used to merely display columns is read-only state, while Edit Form can be used for editing and viewing records.
Now, when using Edit Form:
1. Creating new Record => Use NewForm(Form1) to set Form as new FormMode which will be initiated to create a new Record in the datasource. All columns will be blank so User can enter data.
2. When editing existing record => Use EditForm(Form1) and then pass which Record you want to edit in "item" property of the Form.
3. For Viewing the EditForm in view state, simply change FormMode.View which will turn entire form to act as ViewForm.
4. Note: In order to show the Form when in playmode, make sure the Form is initalized as NewForm() or EditForm().
Hope this helps
That's all generic items that I've already reviewed. My Edit form matches the instructions but it's just not working. I'm baffled as to why that might be the case that a View Form and Edit Form can have identical item and database information but the edit form doesn't show the data.
Hi
Hope this helps for you!
https://powerapps.microsoft.com/en-us/tutorials/working-with-forms/
If this post helps, please consider accepting it as the solution.
MS.Ragavendar
10
LC-26081402-0
6
EE-04041031-0
4