Whenever a ‘Text’ field is empty, for example, if ‘Metrics’ isn’t filled out by the user, I want to add a ‘1’ in the ‘Incomplete Fields’ section. The same goes for all unfilled fields. Played about for a few hours with Conditions etc but can’t seem to figure this out!
With 14 fields, I’d probably use JavaScript for this personally, to keep it simpler and cleaner, but you can do it in vanilla Bubble if you prefer, with the following method.
Have 3 groups to act as variables, all of type ‘number’
The first one is the total number of input (i.e. a static value of 14)
The second one is the count of completed inputs, and the datasource for this is just each input’s value is not empty: formatted as number (where the number for yes is 1 and the number for no is 0) + the same for each other input.
e.g.
input 1's value is not empty: format as number + input 2's value is not empty: format as number + input 3's value is not empty: format as number + input 4's value is not empty: format as number
And the third variable is for the incomplete fields - which is the total number of fields minus the completed fields.
Total number of inputs (Static value of 8), am I writing this condition in this section? I.e., the section were I want to display the number of missing fields?
RE: the second variable, I think I’ve got this one figured thanks to your example. Just to double-check the ‘Input 1’s value is not empty +’. Is this added in the ‘Condition’ section, or the appeaence section of the Missing Field entry (4)?
Same goes for the 3rd variable, where would I put this?
Sorry for the 20 questions - I’m newish to Bubble and it’s a steep learning curve!
If it makes things easier, this data / inputs I’m refering to IS included in Data Types under ‘Prospect’. So would ‘Current Prospects Metrics is Empty: formatted as a number + Current Prospects Economic Buyer is Empty…’ work?