Reading field
-
Hi CodePeople,
I have a calculated field (fieldname2) that either shows a number with % or a number with €:
IF(fieldname1==1,FORMAT(fieldname18, {prefix:””, suffix:”%”, groupingsymbol:”.”, decimalsymbol:”,”, currency:false}),
FORMAT(fieldname18, {prefix:””, suffix:” €”, groupingsymbol:”.”, decimalsymbol:”,”, currency:true}))Works fine. Now when I add another calculated field, it is possible to “read” if its % or €? I tried the following things but it doesn’t show anything:
IF(INCLUDES(fieldname2, “€”), fieldname2,fieldname3)
function die(fieldname2) {
if (fieldname2.includes(“€”)) {
return fieldname2;
} else {
return fieldname3;
}
}“Contains” instead of “includes” also doesn’t work … Any suggestions?
Thanks!
PS. I know I could simply repeat the if statement in the calculated field 2 but when its a more complex furmala, the reading would be just more simple ??
- The topic ‘Reading field’ is closed to new replies.