Hi Guys,
When a user recalls one of their requests and the status is "To be submitted", I would like to allow them to edit any field. If the status is anything else I would like to disable all fields.
In the form DefaultMode property, I have put:
If(varStatus="To be submitted",FormMode.Edit,FormMode.View)
When I change this while the form is open the fields disable as expected, but as soon as I go back and navigate to the form again all of the fields are editable.
The DisplayMode property of all of my fields is Parent.DisplayMode
What am I doing wrong?
Thank you so much 😀
Hi @JimJim
Set the OnSelect property of gallery to
If(
ThisItem.Status.Value = "To Be Submitted",
EditForm(EditForm1),
ViewForm(EditForm1)
);
Navigate(
EditScreen1,
ScreenTransition.None
)
When a user selects an item in a gallery, the following code assigns a value to the variable
Set(varStatus,LookUp('Requests', ID = gal_ViewRequests.Selected.ID).Status)
I have shown the value of varStatus in a label and it look fine
Your default mode code looks ok. Show all the code related to varStatus
WarrenBelz
146,609
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
65,946
Most Valuable Professional