goldcougar Posted January 20, 2005 Posted January 20, 2005 We needed to force users to click a "done" button on a window before they could move on for more data entry so we used this technique for creating modal windows: note: this is used for data entry when a new record is being created Create a field called "modalWindowValidation". On the validaion tab for the field, select "Not empty", and "Display custom message if validation fails". In the box for custom validaion message put "You must select the 'done' button before you can move on". Then, in your scripts at the appropriate point, create a new window, go the the appropriate layout, and create a new record, then pause the script. The user can enter their data into the appropriate fields, but if they try to close the window, or click on one of the windows behind it, they will see your custom validation message. Then on the window layout have a button that reads "done", and just resumes the script. The rest of the script will then set the field modalWindowValidation="true" or anything else you want and then close the window.
Oldsneekers Posted January 25, 2005 Posted January 25, 2005 Window validation has been keeping me awake (almost). I'll give this ago. Thanks.
Oldsneekers Posted January 27, 2005 Posted January 27, 2005 I tried the above and nothing happens. My data input and edit layouts are with global fields. For new records, the user enters data into global fields, my script looks for erros or empties, and if OK, makes a new record and setfields the data from globals to regular text fields. For edit windows, the data is setfield from text fields to globals and these globals on on the layout. The enter script looks for unwanted duplicates and entered the data. For edits a record already exists (in the background). I tried the above validation and even for edit windows. I did not get the vaidlation failure message when i clicked ouside the window. I tried making the field a regular text field as well as a global without any impact. Am I doing something wrong?
goldcougar Posted January 28, 2005 Author Posted January 28, 2005 Ok, I appologize, I just did a quick test file and you do not get the popup when you click one of the background windows. You will see the popup only if you try to close the window. If you try to click on a background window, it just doesn't do anything, but keeps only the modal window active. I have attached an example. ModalWindow.zip
jfortes Posted October 25, 2005 Posted October 25, 2005 Just use the script step allow user abort off in the script you leave paused and the user wont be able to click in any other window. New problem. What if you have to use the halt script command in some process of the modal window? you will also kill the paused script and the window will not be modal anymore.
Recommended Posts