Hi guys!
I'm having trouble setting up a button so the user can view the details of information filled in a form
Example:
I'd like when users click on the "arrow" they would be taken to a page where they can view all the form fields they filled in, however when the user does this they get the following error:
"No items to display"
My button has the following code in the "OnSelect" function:
Select(Parent);;Navigate(Tela_Detalhes_Clientes_Inclusao)
Tela_Detalhes_Clientes_Inclusao is the name of the screen that my detail form is on
Solved! Go to Solution.
Hi,
You need to "take the record with you".
Change your code to Select(Parent); Set(varSelectedRecord, ThisItem);Navigate(Tela_Detalhes_Clientes_Inclusao)
Then, on the form that is in Tela_Detalhes_Clientes_Inclusao set the Item to varSelectedRecord (if you are using a form). Otherwise, just drop in the controls you want and set to to varSelectedRecord.YourColumns
Yes. On the form, you should also set the Datasource property to your table.
Is your default form mode set to Edit or New?
In the tab to fill in the form, the Default Mode is set to "Edit"
I've noticed sometimes I have to change the form mode to New and then switch it back for it to work correctly. But also, I would write in a variable for the form mode for making new ones and editing existing records.
I have this on my new entry Icon
Set(varFormMode, Defaults('MyFormName'))
I have this bit in mine to edit a previous entry from a gallery.
Select(Parent);Set(varFormMode,Gallery6.Selected);Navigate(Screen3);
You then will add that variable varFromMode to your Item for the form.
Good luck!
Hi,
You need to "take the record with you".
Change your code to Select(Parent); Set(varSelectedRecord, ThisItem);Navigate(Tela_Detalhes_Clientes_Inclusao)
Then, on the form that is in Tela_Detalhes_Clientes_Inclusao set the Item to varSelectedRecord (if you are using a form). Otherwise, just drop in the controls you want and set to to varSelectedRecord.YourColumns
it worked!! Thanks!
Hi!
The code works for 1 gallery, however when I put the same code in the other gallery both didn't work.
What should I do?
I have to configure this same code for 3 galleries
I can't see a reason it should stop working for gallery 1 even if it doesn't work for 2 and 3.
All those 3 galleries are in the same screen? Why are there different id numbers?
All galleries are on the same screen.
My app has 3 forms, to save screens I chose to put the 3 galleries on the same screen. Do you think this is the cause of the error?
No, not at all. What confuses me is why you would want to have the same record in all 3 galleries, because that is what you will get if all galleries have varSelectedRecord in Items
User | Count |
---|---|
125 | |
87 | |
86 | |
75 | |
69 |
User | Count |
---|---|
216 | |
181 | |
140 | |
97 | |
83 |