web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / PowerApps add score to...
Power Apps
Unanswered

PowerApps add score to Yes, No and NA Radio button

(0) ShareShare
ReportReport
Posted on by 45

JohnGerald_0-1659456604785.png

JohnGerald_1-1659456678434.png

JohnGerald_2-1659456898237.png

 

 

Hello Folks, I'm working on an Audit app for my team and kind of stuck here... The functionality I need here is, If I select "Yes" or "NA" the points for the particular question should be updated. In this case its 6 points. If I select "No" then the points should be 0 for the initial question and -6 for the other questions as applicable. For now, I've managed to get only till here, but then this formula works for every single click, let's say if I select Yes first and then NA it adds 6+6. I just needed it to be 6 for the question and 0 or -6 incase of "No"... Any help is greatly appreciated. I'm really new to this and learning by our community's help.

 

Categories:
I have the same question (0)
  • jorge.daniel Profile Picture
    1,430 Super User 2024 Season 1 on at

    Can you provide any information on you datasource? What is your datasource, how is you data modelled?...

  • Sumaira_Noor Profile Picture
    18 on at

    @John-Gerald 

    Try below

    If(yourRadioButtonName.Value="Yes",6,If(yourRadioButtonName.Value="No",0,-6))

  • bapala Profile Picture
    247 on at

    Hi @John-Gerald,

     

    It would be great if you can provide a data source where you are saving your data and how?

    If I understood your question correctly, you can use something like below:

    bapala_0-1659467665681.png


    And use the 'label.Text' in Patch function to add this value to the data source.

     

    Same goes for second question as well:

    bapala_2-1659467911561.png

     

    Hope this helps...!

  • John-Gerald Profile Picture
    45 on at

    Thank you folks for your valuable time... The data source I use is SharePoint lists. I'm trying to do a similar "MS Forms/Quiz" kind of feature, but here is just 1 answer for every question. Scoring for "Yes" and "NA" is 6 and for "No" its 0. Do let me know if you need anything else. 

  • John-Gerald Profile Picture
    45 on at

    @jcfDaniel I've used  SharePoint Lists as a data source here 😊

  • John-Gerald Profile Picture
    45 on at

    @bapala this didnt work actually. 

  • John-Gerald Profile Picture
    45 on at

    @Sumaira_Noor This didnt work either, since I store the values on a global variable (PointsScore)

  • John-Gerald Profile Picture
    45 on at

    I think I've found a solution, working on it. Will keep you all updated post-testing.

  • Verified answer
    John-Gerald Profile Picture
    45 on at

    I found a way to solve this problem... I created a set of new global variables for each of the question responses and then displayed them on each label - used this for each questions, renaming them as Q1,Q2,Q3, etc. 

     

    If(Q1PointsScore=0,If(Radio1.Selected.Value="Yes",Set(Q1PointsScore,Q1PointsScore+6))); If(Q1PointsScore=0,If(Radio1.Selected.Value="NA",Set(Q1PointsScore,Q1PointsScore+6)));
    If(Q1PointsScore="",If(Radio1.Selected.Value="No",Set(Q1PointsScore,Q1PointsScore+0-6)));
    If(Q1PointsScore=6,If(Radio1.Selected.Value="No",Set(Q1PointsScore,Q1PointsScore+0-6)));

     

    Appreciate everyone's time and effort. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 717 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 329 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard