Discussions

Expand all | Collapse all

Multiple Field Validation Check

  • 1.  Multiple Field Validation Check

    Posted 07-18-2019 15:02
    Hi,

    I am trying to setup some sort of validation check to see if something has been uploaded, but I wasn't sure how to code would look.

    Basically I have 15 picture attachment fields and I have a formula checkbox field that I want "true" if more than one picture has been uploaded. So if "Picture 1" has something in it and "Picture 9", it should say true or be "checked", but if only "Picture 3", for instance, is the only field that has a picture in it, the checkbox should be false. I didn't know if there was some sort of function that lets you check for multiple fields that if 2 or more equal true then true, and I didn't want to setup a hundred line case or if statement.

    Any ideas?


  • 2.  RE: Multiple Field Validation Check

    Posted 07-18-2019 15:07
    var number NumberOfAttachments = Count(
    ToText([File 1])<>"",
    ToText([File 2])<>"",
    ..etc

    ToText([File 15])<>"");

    IF($NumberOfAttachments >0, "Sorry, But just 1 attachment allowed per record and you have " & ToText($NumberOfAttachments ))




  • 3.  RE: Multiple Field Validation Check

    Posted 07-18-2019 15:17
    Works beautifully! Thanks Mark