Avatar

Level 2

The reason for the issue was the context of the script and the scope of the objects being referred to was incorrect.

You can use either

Textfield.validate.nullTest =  "error"

or Textfield.mandatory = "error"

Both will work