0

How do I code the following: Select from a combo box, each item has a value, the value reflects in a different filed. If there is nothing selected then the value in the field must be 0?

if text('Year 1 2017') = "Council Reg" then
            'Council Registration' := "1200"
else
            "0"

3 replies

null
    • Nick
    • 5 yrs ago
    • Reported - view

    Try this:

    if text('Year 1 2017') = "Council Reg" then
                'Council Registration' := "1200"
    else if text('Year 1 2017') = false then
                "0"

    • Johan van Schalkwyk
    • Johan
    • 5 yrs ago
    • Reported - view

    Thanks Nick, perfect, however, when I select one of the other items on the combobox with a values then the "Council Reg" revert back to "0" - how do I select more than one and still keep the value of the already selected value in their fields ? If I select "Council Reg" then the value in the field is 1200, plus then I selct WPTP 1 with a vaue of 2000 in a diferent/next field. This gives me a total value of 3200. (I have about 6 posible items to select from. (this is my first time using Ninox, with no coding knowlage, so forgive the ignorance) 

    • Nick
    • 5 yrs ago
    • Reported - view

    Some screen shot would be nice. I need more details... what type of fields are you using etc.

Content aside

  • 5 yrs agoLast active
  • 3Replies
  • 1727Views