How do I keep the last saved selected item visible in the combo searchbox after saving the item? (How to avoid losing the last data entry by accidently saving an empty combobox )!
Solved! Go to Solution.
Assuming that your form is in New mode. use YourForm.LastSubmit.Value on the OnSuccess of your form and store the value in a variable, like Set(glbComboValue,YourForm.LastSubmit.Value). then set the Default property of your combobox to this variable
Hi @Englishweb ,
If the purpose of this requirement is to avoid empty saving for the combo box field, then you could achieve this by set below formula in the submit button:
Then set below formula in the Default property of combox box data card:
Here is a visual of the Gallery and corresponding datatable (and the problematic combobox)!
The Textlabels are working perfectly, as is the patch to the datatable. The Combobox reverts to another surname, not the last saved one, which is confusing.
I am trying to get the combobox default to be the same as the text label....
on the Select of your button, get the Last record that was created in your list.
Then set the Default property of your combobox to varLastRecord.myChoice.Value
**Please replace the names with your controls and columns names
I've updated the OnSelect: Refresh(SUMMARYDATATABLE);Set(varLastRecord,Last(SUMMARYDATATABLE));
For the Default properties on the combo box I tried varLastRecord.Student1.Value
but .Value gives an error
Could you use Alt+Button to populate the variable with a value first. it might help.
I don't see an error on my side and it's happy with the Value. but I remember having issues with the Last() function and at some point I considered using the First() function but sort it descending
Thank you for your continued patience.
I think there is maybe a confusion, I probably am not explaining myself clearly. I want the combobox to show the same name as in the data table entry, not the last record in the table. Is this possible? I've been trying to resolve this for days!
Could you please tell me the sequence of the actions that users take to complete that form.
1- User enters the First Name, Surname (it's a textInput control)
2- user enters dates (debut, fin)
3- What does the user do with the comboBox? what is behind the combobox? is it a choice field? a Person or a lookup?
4- user presses Submit (you use Patch() function to create a new record
5- users sees the record that was created in a data able
6- Data table shows the name
Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.
Fill out a quick form to claim your user group badge now!
Attend for two days of expert-led learning and innovation on topics like AI and Analytics, powered by Dynamic Communities
Features releasing from October 2019 through March 2020
Join us for the Microsoft Business Applications Virtual Launch Event on Thursday, April 2, 2020, at 8:00 AM PST.
Innovate, Collaborate, Grow - The top training and networking event across the globe for Microsoft Business Applications