Losing a lot of sleep over this.
I am trying to create a dialogue box that allows the user to enter some search text and then enter some of the advanced search function choices ,either by dropdown choice or by checkboxes, rather like the built in advanced search. Once all the selections have been made a large button labelled SEARCH will then be pressed which will initiate the search of a specific catalogue index
Creating the dialogue box using AcroDialog has been easy.
Getting the various functions within the dialogue to work is proving considerably harder. A lot of the code found in the form examples I've found don't want to work within the confines of a dialog box.
I have two fundamental issues/questions.
Firstly,is it possible and if so how, to take a text value entered into a text edit box and use that in another dialogue element before running the commit function.
Secondly, is it possible to create javascript that will close down (cancel) the dialogue from a normal button.
I do not wish to use an OK_Cancel button arrangement because I wish to use a single OK button, enlarged and renamed to SEARCH to execute the end product of the dialogue box.
I hope that all makes sense and someone may be able to answer my questions.
Many thanks,
Nifty Styles
Using Acrobat 8.2.5 Professional
(Norfolk, England)
When the dialog is running, values are acquired from dialog with the "dialog.store()" function. This is the function that is used in the "Commit" function to store data when the dialog is closed. See that function for an example.
The dialog can be close with the "dialog.end()" function. This function has a single input, which is a string that is returned by the "app.execDialog()" function. Calling this function does cause the dialog to call the commit or validate functions.
Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script