cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
DevendraV
Resolver I
Resolver I

Set dropdown value based on selection of Listbox

I am having dropdown and listbox in a seperate screens and both are being loaded with same choice column values. I have more than 20 choice values so i have added a lisbox for users to select the value and then comeback to dropdown once they select the value from Listbox to fill the other fields in the form.

 

When users select the value from dropdown based on that value i am able set the listbox value.

 

Set(RisksSelected,Dropdown.Selected.Value);Navigate(Screen2,ScreenTransition.None)

But when usr select a value from list box i am unable to set the dropdown value. I tried the code below onChange event of Listbox 

 

Navigate(RisksScreen,ScreenTransition.Fade,{MY:ListBox.Selected})

On default property of Dropdown i tried to set "MY" value but its not working. 

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-xida-msft
Community Support
Community Support

Hi @DevendraV,

 

Could you please shared a screenshot about your app's configuration?

Further, could you please share more details about the Choice type column within your data source?

 

I think there is something wrong with the formula that you provided within the Default property of the Dropdown control. The Default property of the Dropdown control is required to provide a text value, but the ListBox.Selected formula would return a record value.

 

I have made a test on my side, and don't have the issue that you mentioned. Please take a try with the following workaround:1.JPG

 

2.JPG

 

Set the OnChange property of the List box control to following formula:

Navigate(RicksScreen,ScreenTransition.Fade,{My:ListBox1.Selected.Value})

Set the Default property fo the Dropdown control to following formula:

My

The GIF image as below:Test1.gif

 

 

Note: Please make sure the SelectMultiple property of the List box control set to false.

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-xida-msft
Community Support
Community Support

Hi @DevendraV,

 

Could you please shared a screenshot about your app's configuration?

Further, could you please share more details about the Choice type column within your data source?

 

I think there is something wrong with the formula that you provided within the Default property of the Dropdown control. The Default property of the Dropdown control is required to provide a text value, but the ListBox.Selected formula would return a record value.

 

I have made a test on my side, and don't have the issue that you mentioned. Please take a try with the following workaround:1.JPG

 

2.JPG

 

Set the OnChange property of the List box control to following formula:

Navigate(RicksScreen,ScreenTransition.Fade,{My:ListBox1.Selected.Value})

Set the Default property fo the Dropdown control to following formula:

My

The GIF image as below:Test1.gif

 

 

Note: Please make sure the SelectMultiple property of the List box control set to false.

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Power Apps June 2021

June Power Apps Community Call

Don't miss the call this month on June 16th - 8a PDT

Top Solution Authors
Top Kudoed Authors
Users online (43,089)