You can do something like that but it would not be very secure.
1. You woudl have to change the built in submit button for a regular button so that you can add code to it.
2. You could replicate the submit functionality (it has been discussed many times on this forum).
3. You could add a field (hidden of course) that woudl act as a flag to indicate that the form has been submitted (as opposed to being saved by the user).
4. On th esubmit button you woudl put a value (like "Submitted") into the hidden field.
5. On the Doc Ready event of the form1 node you coudl add script that acts like this:
if (flagFieldName.rawValue == "Submitted"){
var pswd = app.response("Enter the password to open the form!");
if (pswd != "your magic password goes here") {
app.alert("Password is not correct!")
app.execMenuItem("Close")
}
}
You could make this code more robust (allow 3 tries at the password etc ....but teh technique is the same.
Make sense?
Paul