Validation: avoid to set a past date!

Hello experts,

I'm writing a validation on SM 7.11 to avoid users to set a past date in a specific form.

I'm trying to achieve this through the Validations form of SM (I'm not that expert...) and the form seems to me easy and clear:

Form values

file=fileName
form=formName
field=$value9

 

Query

Add: false
Update: $value9 in $file<tod()
Delete: $value9 in $file<tod()
Set Focus to: $value9 in $file

 

As result I receive back this error:

Process panel calc.validations in RAD format.cval encountered error in line 8 (format.cval,calc.validations)
Cannot evaluate expression (format.cval,calc.validations)
Cannot evaluate expression (format.cval,calc.validations)
Cannot evaluate expression (format.cval,calc.validations)
Cannot evaluate expression (format.cval,calc.validations)
Bad arg(1) oper = (format.cval,calc.validations)
Cannot evaluate expression (format.cval,calc.validations)
Cannot evaluate expression (format.cval,calc.validations)
Bad arg(1) oper  and  (format.cval,calc.validations)
Cannot evaluate expression (format.cval,calc.validations)
Bad arg(1) oper < (format.cval,calc.validations)
Cannot evaluate expression (format.cval,calc.validations)
cannot use TIME as index (format.cval,calc.validations)
Validation expression no: 22 CANNOT be evaluated.

 

My Validation is the °22 in order so I assume I wrote something wrong obviously. I looked for this error but I did not found anything useful.

  • Can you help me to achieve this through this validation?
  • Also, is it possible to achieve the same through a JS script? If yes, can you please be so kind to write me an example?
  • Last but not least, is there some specific manual or white paper to helo me understand the logic of SM format control?

 

Thanks to all.

 

 

Luca

Tags: