I've been writing a script for generating sequential part numbers, and have run into some odd things that some here may have encountered. I should note that I'm a novice at Java. This is based on a JFrame with a few drop-down boxes and text entry boxes followed by a button to start the process.
My first question: when recording a script a run() function and run0() function are created, and the run() calls the run0(). Is there a rule that says the run0() will only start from the run() function? I've tried to change that, mainly due to the event that controls the start button, butthe IL. commands will onlywork if the run0() function is called from run().
Second question: does anyone know of a clean way to exit or cancel from a JFrame in an Intralink script? Using system.exit closes all Intralink windows, not just the script dialog. Using the hide or dispose functions close the dialog but lock up the script. I need a way to let the user exit without running through the script via the "Done" button.
Third question: has anyone had a script that runs fine from the Scripting Options window but not when it is run through the Custom menu in Intralink? My script, when run through the Custom menu, works well half the time but the rest of the time, when started, acts like the "Done" button has already been pressed.
At least two of these problems could be eliminated if Iused the JOptionPane.showInputDialog instead of the JFrame but I wanted all the options in a single dialog box instead of several. Any suggestions?
My first question: when recording a script a run() function and run0() function are created, and the run() calls the run0(). Is there a rule that says the run0() will only start from the run() function? I've tried to change that, mainly due to the event that controls the start button, butthe IL. commands will onlywork if the run0() function is called from run().
Second question: does anyone know of a clean way to exit or cancel from a JFrame in an Intralink script? Using system.exit closes all Intralink windows, not just the script dialog. Using the hide or dispose functions close the dialog but lock up the script. I need a way to let the user exit without running through the script via the "Done" button.
Third question: has anyone had a script that runs fine from the Scripting Options window but not when it is run through the Custom menu in Intralink? My script, when run through the Custom menu, works well half the time but the rest of the time, when started, acts like the "Done" button has already been pressed.
At least two of these problems could be eliminated if Iused the JOptionPane.showInputDialog instead of the JFrame but I wanted all the options in a single dialog box instead of several. Any suggestions?