Forum Discussion
GiuseppeMacri
6 years agoQrew Captain
var text Warnings = List("<br>",
If([Data Element 1]<>"","","Data Element 1"),
If([Data Element 2]<>"","","Data Element 2")
If($Warnings <>"", "<span style=\"color:red;font-size:110%; font-weight:bold\">Missing Information:<br>" & $Warnings)
This is the larger formula, I am not using any checkbox fields for support, only binary numeric fields (aka only values are 0 or 1)
------------------------------
GMacri
------------------------------
BrandonDrake
6 years agoQrew Cadet
Hi GMacri,
Is this the exact formula that you are using in the Rich text field? If it is, it seems as though you are missing some syntax. I think you would need to add the two highlighted characters to show the end of the List and to end the variable declaration. This should clear up any errors in the formula, so long as your Data Element fields are of a type that can be compared to "blank" and does not require the isNull() function to be used.
var text Warnings = List("<br>",
If([Data Element 1]<>"","","Data Element 1"),
If([Data Element 2]<>"","","Data Element 2"));
If($Warnings <>"", "<span style=\"color:red;font-size:110%; font-weight:bold\">Missing Information:<br>" & $Warnings)
If there are not any errors in the function that you are using, what is the result of this field when used in the live application? This formula seems to work as expected in my test.
------------------------------
Brandon Drake
JHI Group
Monroeville OH
------------------------------
Is this the exact formula that you are using in the Rich text field? If it is, it seems as though you are missing some syntax. I think you would need to add the two highlighted characters to show the end of the List and to end the variable declaration. This should clear up any errors in the formula, so long as your Data Element fields are of a type that can be compared to "blank" and does not require the isNull() function to be used.
var text Warnings = List("<br>",
If([Data Element 1]<>"","","Data Element 1"),
If([Data Element 2]<>"","","Data Element 2"));
If($Warnings <>"", "<span style=\"color:red;font-size:110%; font-weight:bold\">Missing Information:<br>" & $Warnings)
If there are not any errors in the function that you are using, what is the result of this field when used in the live application? This formula seems to work as expected in my test.
------------------------------
Brandon Drake
JHI Group
Monroeville OH
------------------------------
- GiuseppeMacri6 years agoQrew CaptainI was missing some syntax in the example but not in the app. This formula works in different apps, just not this one. I suspected IOL might of been the issue but i've since removed those fields from my forms and its still shooting errors
------------------------------
GMacri
------------------------------- BrandonDrake6 years agoQrew CadetAt what point are you getting these errors? Is it when you try to save the formula, view a record, save a record.?.?
------------------------------
Brandon Drake
JHI Group
Monroeville OH
------------------------------ - BrandonDrake6 years agoQrew Cadet
Here is what the formula does in my test. Is this supposed to be the final result?? Or should the Data Element fields contain that text as well?
------------------------------
Brandon Drake
JHI Group
Monroeville OH
------------------------------