cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Help needed with advanced function!

Hello,

 

I am currently working on an app Where I display three values in a drop down list: Expectation Not Met, Expectation Met, Expectation exceeded. I need to be able to display the text but be able to add the values 1,3,5 to the text so I can average out the scores. 

 

Does anyone know a method to be able to assign a number value to text or how to properly find averages from a dropdown?

 

Anything will help. Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Help needed with advanced function!

Hi @Anonymous 

 

You can test with @Pstork1 's method, and there is another choice is you can use Table function.

 

Example:

Dropdown.Items=Table({Name:"Expectation Not Met",score:1}, { Name:"Expectation Met", score:3},{Name:"Expectation exceeded",score:5})

(Then  you can use the DataTable or other controls can check your formula expression)

Table.PNG

 

More information:

function-table

 

Hope this could be helpful.

 

Best Regards.

Yumia

View solution in original post

2 REPLIES 2
Dual Super User
Dual Super User

Re: Help needed with advanced function!

Build your dropdown values as a collection using the following:

 

ClearCollect(dropdownvalues,{Name:"Expectation Not Met",score:1},{ Name:"Expectation Met", score:3},{Name:"Expectation exceeded",score:5})

 

Bind the dropdown to that collection and set the Value property to Name.  Now you can access the value associated with the name using dropdown1.selected.score



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.
Community Support Team
Community Support Team

Re: Help needed with advanced function!

Hi @Anonymous 

 

You can test with @Pstork1 's method, and there is another choice is you can use Table function.

 

Example:

Dropdown.Items=Table({Name:"Expectation Not Met",score:1}, { Name:"Expectation Met", score:3},{Name:"Expectation exceeded",score:5})

(Then  you can use the DataTable or other controls can check your formula expression)

Table.PNG

 

More information:

function-table

 

Hope this could be helpful.

 

Best Regards.

Yumia

View solution in original post

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 (3,826)