5 Replies Latest reply on Apr 6, 2016 4:49 PM by Extensitech

    Scripted data validation


      Hi there


      Trying something simple here which has be stumped a bit.  I'm not keen on the FM native field validation routine for what I'm doing as I don't need it for every instance of the field I'm working in, just the instance on this particular layout.


      I need the user to enter a Code in one field, then in another, enter a Description.


      I've got the following:


      Layout Entry - Go to Field [Code]


      Script Trigger on Code




      If IsEmtpy(Code)

      Custom Dialog "Error! Please enter a code"

      End If

      Go to Field (code)


      I want the user to be directed back to the Code field, but this is not happening.  It's like the script stops immediately after the EndIf and leaves the cursor out there on the layout wherever the user clicked, resulting in the possibility of an empty field.


      Any ideas what's happening here and how to fix it?  Such a seemingly simple thing.


      Thanks in advance