Ok so here's an update and another question:
I have created a basic form to work on and try and resolve this issue. It has one field in one subform and two buttons. The script I am using on the click event of button 1 is as follows:
if (form1.textField1.rawvalue==null) then
xfa.host.messageBox("you must fill this field")
else
form1.access = "readOnly";
endif
Button2.execEvent("click")Button 2 is an email submit button.
This seems to do what I want but my actual form has lots of fields in multiple subforms. Is there a way to amend the above - or write something totally new - so that I don't have to go through and write up all the fields I want checked into the script?