Skip to main content
Inspiring
December 23, 2019
Question

Not equal to NULL and not equal to zero

  • December 23, 2019
  • 2 replies
  • 2278 views

I've seen a lot of posts on how to compare a value to v_null in order to make sure a field is not left blank. I'm trying to solve the opposite -- I need some fields to actually be blank and can't figure it out. 

 

Help! (please!)

This topic has been closed for replies.

2 replies

New Participant
October 22, 2022

I'm trying to accomplish the same thing and what occurs to me after reading this is to attach an action so that if the user even clicks on an unacceptable blank it assigns that blank's variable as Done. Then, you can add to the advanced action that if "unwanted blank" = Done it marks it wrong. If ≠ Done marks it right. I'll see if that works for me.

Lilybiri
Brainiac
December 23, 2019

The variable v_null appeared in one of my blog posts 9 years ago, see that it has been taken over by many. That post has been updated recently:

http://blog.lilybiri.com/where-is-null-in-cp2017

Can you explain exactly what you want to do? Normally the logical expression with 'equal to v_null' should work.

Inspiring
December 23, 2019

Thank you so much for replying.

Our project is teaching users how to fill out specific forms. In many cases it is imperitive that the user understand that the standard is to leave a field blank vs entering a zero. 

 

Equal to null works... but so does entering zero.

 

I've tried 'contains' as well, no joy.

Inspiring
December 24, 2019

Oops, never wrote such a long advanced action with so many decisions, and on top of it always an ELSE part. 

Think there should be a better way, or switch to JS which may be necessary anyway. Please use states instead of show/hide, will probbably make everything a lot easier.


Did you try to put the zero in anoter variable v_zero for the comparison? 


No luck with the zero being in a variable. 😞

 

I don't disagree with you about the JS, this would be much easier that way, but unfortunately we've been told to do it without. Perhaps when my boss understands that what he wants can't be done without JS he will change his mind. 

 

I do appreciate your help with this!