There are two ways how to run the script when DIAdem launches:
- Using built in option that allows a script to run upon DIAdem starting up. (Available for DIAdem 10 and later)
Follow the steps below to use this setting.
- Launch DIAdem and open one of the DIAdem panels.
- Select Settings»DIAdem Settings»General.
- Click the Browse button next to the Start script category.
- Select the script you want and click load.
- Click OK and then exit DIAdem.
- Upon exiting DIAdem, a dialog box will appear asking you if you want to save your changes. Click Save and Exit.
Restart DIAdem and notice after the program starts, DIAdem runs the specified script.
- Launching DIAdem with "/c" Start Parameters
Follow the steps below to run a script upon DIAdem launching:
- Navigate to your DIAdem directory typically located at the path C:\Program Files\National Instruments\DIAdem x.x
- Right-click on DIAdem.exe and select Create Shortcut.
- Right-click the new shortcut and select Properties.
- In the shortcut tab, there is a textbox called Target with the path to the DIAdem executable. Append to the end of the text, /cscriptstart('path to your script'). For example, if you have a script on the C drive called Demo.vbs, the entire entry for the Target textbox should read: "C:\Program Files\National Instruments\DIAdem xx\DIADEM.exe" "/cscriptstart('C:\Demo.vbs')"
- After entering the above text, click OK.
- Double-click on the shortcut and notice after the program starts, DIAdem runs the specified script.
Additional Information
In DIAdem 9.1 and earlier, there is no built in option that allows a script to run upon DIAdem starting up - for those versions you will need to use second method presented in this article.