Avatar

Level 7

Well you are missing the " around the text in your messagebox but even then it doesn't seem to work. I am not a javascript expert so am not sure why but it works in formcalc like this:

if(Len($) > :smiling_face_with_sunglasses: then

    xfa.host.messageBox("Enter eight digits for the date in the format YYYYMMDD or use the drop down calendar.")

    xfa.host.setFocus("$")

endif