0

IF TEXT FIELD DOES NOT CONTAIN THE LETTER "Q" THEN ....

I've got an RTF that triggers another field on a different tab. When there's something in the RTF, the other field displays an icon. So far so good. But if I paste in text on the RTF, the icon doesn't always go away. Deleting and backspacing the blank RTF sometimes does it, but not always. Seems like there's some hidden html or something?

Anyway, a quick fix might be to make the trigger code identify whether or not actual text is there (rather than if 'FIELD A' !=null), but I'm not sure how to code a 'does not contain' phrase. 

6 replies

null
    • David
    • 4 yrs ago
    • Reported - view

    SORRY, SHOULD HAVE REREAD BEFORE I POSTED. HERE'S A CLEARER VERSION:

    I've got an RTF into which I can paste questionnaire replies. If I paste something in, a function field on another tab detects this (condition: if FIELD A !=null) and displays an icon.

    So far so good. But if I then delete the pasted text and save the RTF, sometimes the other field keeps displaying the icon. In some cases the icon will go away if I delete and backspace inside the empty RTF - but not always. Seems like there's some hidden html or something?

    Anyway, a quick fix might be to make the trigger code identify whether or not actual text is there (vs. "not null"), but I'm not sure how to code a 'does not contain' phrase. 

    • Mconneen
    • 4 yrs ago
    • Reported - view

    Hmm.. interesting.. and I COULD repeat the same.  What is also interesting is the length(text('Rich Text')) was ZERO when I selected all and hit the delete key.   So.. perhaps as a work around.. Check the length(text('Field A')) > 0 .... then NOT empty.. 

    richText

    • David
    • 4 yrs ago
    • Reported - view

    Ah great idea. Many thanks!

    • Ninox partner
    • RoSoft_Steven.1
    • 4 yrs ago
    • Reported - view

    Or create a button to clear your RTF > 'Rich Text' := null

    • Mconneen
    • 4 yrs ago
    • Reported - view

    @Steven... +1 .. good idea and saves a few steps opening / selecting / deleting..   I LIKE IT. 

    • David
    • 4 yrs ago
    • Reported - view

    Thanks, Steven. Pity that it's necessary, but a clean solution!

Content aside

  • 4 yrs agoLast active
  • 6Replies
  • 1725Views