cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ricky703canada
Frequent Visitor

Drop-down field in gallery reverts back to default value

Hello,

 

I have a drop-down field added in a gallery and I am using save icon to save it to a collection.  But when I save one item, the drop-down value reverts back to default value.  I would like to keep the value of the drop-down.  For e.g.  I have a drop-down field called "Deviation Code" added in a gallery.  I have selected DevCode1 as one of the values.  I click on save and new row is added but this first row the "Deviation Code" reverts to default blank.  How can I make sure it doesn't revert to blank? I want to preserve the previous value of the drop-down in the drop-down field.

 

Thanks,

Ricky

 

1 ACCEPTED SOLUTION

Accepted Solutions

Hi@ricky703canada,

Could you please tell me that

  1. does this drop-down field exist in the data source that you fill in the Gallery
  2. how you set the Items property of the drop-down control?
  3. is it a Combo Box or a Dropdown?

Actually, if you want the drop-down control within the Gallery to keep the selected value for the current item, you should make the drop-down field exist in the table that you populate the Gallery with.

The ThisItem parameter is connected to the table that you set Items property for the Gallery, it will display the corresponidng column value in this table.

So in a word, if you want to keep the drop-down control selected value, you should add this field to the data source that you fill in the Gallery. Then you could set the Default/DefaultSelectedItems(depends on if it is a Dropdown or Combo Box) as below.

If you have make the drop-down field exist in the table that you populate the Gallery with, you could set the Default property of the Dropdown as below:

ThisItem.'drop-down field name'

Hope it could help.

Regards,

Qi

 

 

Best Regards,
Qi

View solution in original post

2 REPLIES 2
ricky703canada
Frequent Visitor

For e.g. I have a field called "Deviation Code" that I have chosen to "DevCode1". 

 

ricky703canada_2-1615519194420.png

 

If I click on save icon, it will reset it to blank.  

 

ricky703canada_1-1615519151022.png

 

I want this field to remain with the value "DevCode1" and next row should open with blank value.

 

Hi@ricky703canada,

Could you please tell me that

  1. does this drop-down field exist in the data source that you fill in the Gallery
  2. how you set the Items property of the drop-down control?
  3. is it a Combo Box or a Dropdown?

Actually, if you want the drop-down control within the Gallery to keep the selected value for the current item, you should make the drop-down field exist in the table that you populate the Gallery with.

The ThisItem parameter is connected to the table that you set Items property for the Gallery, it will display the corresponidng column value in this table.

So in a word, if you want to keep the drop-down control selected value, you should add this field to the data source that you fill in the Gallery. Then you could set the Default/DefaultSelectedItems(depends on if it is a Dropdown or Combo Box) as below.

If you have make the drop-down field exist in the table that you populate the Gallery with, you could set the Default property of the Dropdown as below:

ThisItem.'drop-down field name'

Hope it could help.

Regards,

Qi

 

 

Best Regards,
Qi

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Top Solution Authors
Top Kudoed Authors
Users online (1,229)