Formula with COUNTIF and Checkbox

DanielGD
DanielGD ✭✭✭✭
edited 12/09/19 in Formulas and Functions

I have this working formula: 

="Unit 2G  is " + ROUND((COUNTIF([Unit Name]:[Unit Name], "2G") / 14) * 100) + "% Completed"

2G could also be 3G, 4H, and 2H. (Dropdown selection list)



I have a checkbox column named: "Task Completed?"

How would I use the working formula to not do the calculation until the checkbox is "Checked"

Thanks

Tags:

Comments

  • Andrée Starå
    Andrée Starå ✭✭✭✭✭✭
    edited 03/31/19

    Hi Daniel,

    Try something along the line of.

    =IF([Task Completed]@row = 1; "Unit 2G  is " + ROUND((COUNTIF([Unit Name]:[Unit Name]; "2G") / 14) * 100) + "% Completed")    

    The same version but with the below changes for your and others convenience.    

    =IF([Task Completed]@row = 1, "Unit 2G  is " + ROUND((COUNTIF([Unit Name]:[Unit Name], "2G") / 14) * 100) + "% Completed")

    Depending on your country you’ll need to exchange the comma to a period and the semi-colon to a comma.

    Did it work?

    Have a fantastic week!

    Best,

    Andrée Starå

    Workflow Consultant @ Get Done Consulting

    SMARTSHEET EXPERT CONSULTANT & PARTNER

    Andrée Starå | Workflow Consultant / CEO @ WORK BOLD

    W: www.workbold.com | E:andree@workbold.com | P: +46 (0) - 72 - 510 99 35

    Feel free to contact me for help with Smartsheet, integrations, general workflow advice, or anything else.

  • ricki
    ricki ✭✭✭✭✭✭

    You could also use the countifs formula to do something like this

     

    ="Unit 2G  is " + ROUND((COUNTIFS([Unit Name]:[Unit Name], "2G",[Task Completed]:[Task Completed],1) / 14) * 100) + "% Completed"

     

Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!