cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
anilc59
Level: Powered On

Unable to get the first value form the list box without selection

Hi All,

 

I am developling one apps on survye, facing problem with the list box item.

 

I am getting number of result in the list box and wanted to show only the first item of the list boxt to my one of the text box / label.

 

thank in advance

 

 

6 REPLIES 6
Microsoft dinusc
Microsoft

Re: Unable to get the first value form the list box without selection

Hello @anilc59

I don't think there's a way to obtain the first value from the listbox. You you could do however is to take the first value from the formula that is set on the listbox control. Let's say that your listbox formula is something like Filter(SomeSource, MatchingColumn = "Filter Value") in which case the first item would be First(Filter(SomeSource, MatchingColumn = "Filter Value")).Value

The ".Value" is the field name that you want to display in your text box and may be different in your case.

anilc59
Level: Powered On

Re: Unable to get the first value form the list box without selection

Thanks for your comments.

 

I have already done the filter in the listbox, my result will always have single item result in list box. I just want to push that single list  box result to SharePoint as without selection it is not possible to know the value of the first item in the  list box.

My Question is that is there is any way to get the list box value to any control, so form that control I can push the value to the Sharepoint.

 

Thanks and Regards

Microsoft dinusc
Microsoft

Re: Unable to get the first value form the list box without selection

As mentioned, there's no way to get the unselected value from the listbox. My point though is that you should not need to do that. Instead of getting the value from the listbox, you should be able to get it from the formula the listbox is bound to.

Does that make sense?

Community Support Team
Community Support Team

Re: Unable to get the first value form the list box without selection

Hi @anilc59,

 

You can set the Default property of this field's Label control inside the SharePoint edit form to the formula that @dinusc suggested. Then set the DisplayMode of this data card to:

DisplayMode.View

After this, when you submit this record using edit form, this sharepoint field will be updated with the value inside the Label control, which should be one field of the first filtered item in list box.

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
MK1
Level: Powered On

Re: Unable to get the first value form the list box without selection

Hi

 

 

Is there any way to get all items in the listbox into a textbox without selecting them. 

when we choose a product, it has 2-3 different descriptions for it. Which i'm pulling into list box. so that when a user selects the product, he can see all the descriptions available.

But, until we select the description, its not populating into the submit form.i'm trying to save description into SQL table when we submit a request.

Please let me know your thoughts.

 

Thanks again.

MK

MK1
Level: Powered On

Re: Unable to get the first value form the list box without selection

@anilc59

@dinusc

@v-monli-msft

 

Hi

Is there any way to get all items in the listbox into a textbox without selecting them. 

when we choose a product, it has 2-3 different descriptions for it. Which i'm pulling into list box. so that when a user selects the product, he can see all the descriptions available.

But, until we select the description, its not populating into the submit form.i'm trying to save description into SQL table when we submit a request.

Please let me know your thoughts.

 

Thanks again.

MK

Helpful resources

Announcements
New Ranks and Rank Icons in April

'New Ranks and Rank Icons in April

Read the announcement for more information!

Better Together’ Contest Finalists Announced!

'Better Together’ Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

thirdimage

Community Summit North America

Innovate, Collaborate, Grow - The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors
Users online (4,377)