cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
bluelemon247
New Member

Dropdown List from Sharepoint auto fill text when item is selected?

Hello, 

 

I have been struggling ith this one for a while so any help would be greatfully recieved.

I have created a 'JobTypes' dropdown list from a Sharepoint list with two columns - 'JobTypes' and 'Price'

I want a text box next to it to auto populate the 'Price' Value. 


ddname.selected.result, Price does not work and I'm not sure why. 

thank you in advance for any suggestions.

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-qiaqi-msft
Community Support
Community Support

Hi@bluelemon247,

Based on the issue that you mentioned, do you want to populate the TextInput control based on the Dropdown selected?

Could you please tell me that if both of the 'JobTypes' and 'Price' are Text type?

I think there is something syntax wrong with your Distinct() function.

I have a test on my side, please take a try as below.

In my scenario, I have 2 Text columns, 'JobTypes' and 'Price'.

Set the Items property of the Dropdown as below:

 

Distinct(UploadVedio,JobTypes)

 

Set the Default property of the TextInput control as below:

 

LookUp(UploadVedio,JobTypes=Dropdown1.Selected.Result,Price)

 

Note: The 'UploadVedio' is my SP list name, please replace it with yours.

69.png

Please check the screenshot and take a try.

Hope it could help.

Best Regards,

Qi

View solution in original post

8 REPLIES 8
RandyHayes
Super User III
Super User III

@bluelemon247 

What is your Items property for your Dropdown control?  

I am guessing you are using a Distinct function in it as you reference a ".Result" in your post.

What you would want to do is have your Items property be the JobTypes by itself.  Then your dropdown will have the other columns that you want - ddname.Selected.Price will be there as well.

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes
rsaikrishna
Dual Super User
Dual Super User

@bluelemon247 

 

In the Price text box, default property, you can try the following formula:

LookUp(<SharePointList>,JobTypes=ddname.Selected.Value).Price

 

Share your SharePoint list schema information : What type of columns both JobTypes and Price. Is JobTypes a choice column (single selection)?

Also, in the power app, drop down for JobTypes - is it populated from choice column or hard coded values or from another list?

 

Regards

Krishna Rachakonda

If this reply helped you to solve the issue, please mark the post as Accepted SolutionMarking this post as Accepted Solution, will help many other users to use this post to solve same or similar issue without re-posting the issue in the group. Saves a lot of time for everyone.

Thank you for the super speedy reply - The column for JobType is 'single line of text' and the Price column is value. 

Where you hav e put <SharePointList> is this where a URL goes? Sorry I'm basically a complete beginner learning from scratch. 

 

Kind regards

Kate

Thank you for your quick reply - I am using distinct function as the data form method doesn't work for me. Happy to try other methods if this would be better. 

I have changed the dd to 'jobtypes' as suggested but now the dd seems broken and is not coming up with any results.

RandyHayes
Super User III
Super User III

@bluelemon247 
So this is not unusual for dropdowns.  First, make sure the the Value selected in the properties is your JobType.

RandyHayes_0-1606753998595.png

Once you convert to the list as the item source, it usually picks some column that displays nothing.

 

See if that clears it up for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Screenshot 2020-11-30 at 16.39.53.png

So it doesn't seem to want to cooperate - once I changed the dd 'items' input to Distinct(jobTypes) (not Distinct(jobtypes,title) the Value greyed out but before it would still only give me the option of 'Result' 

Quite happy to start this bit from scratch in another way if there's another solution 

 

Kind regards

Kate

v-qiaqi-msft
Community Support
Community Support

Hi@bluelemon247,

Based on the issue that you mentioned, do you want to populate the TextInput control based on the Dropdown selected?

Could you please tell me that if both of the 'JobTypes' and 'Price' are Text type?

I think there is something syntax wrong with your Distinct() function.

I have a test on my side, please take a try as below.

In my scenario, I have 2 Text columns, 'JobTypes' and 'Price'.

Set the Items property of the Dropdown as below:

 

Distinct(UploadVedio,JobTypes)

 

Set the Default property of the TextInput control as below:

 

LookUp(UploadVedio,JobTypes=Dropdown1.Selected.Result,Price)

 

Note: The 'UploadVedio' is my SP list name, please replace it with yours.

69.png

Please check the screenshot and take a try.

Hope it could help.

Best Regards,

Qi

View solution in original post

Hi Qi,

 

This is exactly it! Thank you for solving my problem 😄

 

Kind regards

Kate

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

Top Solution Authors
Top Kudoed Authors
Users online (30,635)