Start an external executable
DigitalMicrograph - Gatan
Mini-example of how the command LaunchExternalProcess() is used. This command can execute any external application. It provides a powerful method to access hardware outside the DigitalMicrograph environment from within DigitalMicrograph.
Use PowerShell to send email
DigitalMicrograph - Gatan
This script uses Microsoft PowerShell to send out an email. Modify the mail server variables before testing.
Having a script wait for a file to appear
DigitalMicrograph - Gatan
Example script which holds its execution until a certain file is found at a given location. Checking is performed on the main thread at given intervals.
Launching an external application and regularly checking if it is still running
DigitalMicrograph - Gatan
Example script showing how the external application Notepad.exe can be launched. The script regularly polls whether or not Notepad.exe is still open so that actions can be performed once the external application is closed.
Run VisualBasic script
DigitalMicrograph - Gatan
Example showing how a VBS script stored as a file on the hard drive can be executed from a DigitalMicrograph script.
Run VisualBasic script directly
DigitalMicrograph - Gatan
Example script showing how a VBS script code can be created as a string variable and directly executed from a DigitalMicrograph script.
Print all image documents with an optional frame
DigitalMicrograph - Gatan
This automation script will print all currently shown images in page mode using the default printer setting. The script will optionally add a rectangular border to the page.
Process all images on a workspace
DigitalMicrograph - Gatan
This automation script applies a processing method to all currently open images. The script is easily modified to perform different tasks on all currently open images.
Scale all images to a given value range
DigitalMicrograph - Gatan
This script normalizes the intensity values of all open images to a defined range [0 - max].
Sort images onto separate workspaces
DigitalMicrograph - Gatan
This automation script iterates over all currently shown images and selects them one by one. The user is asked to press either ALT or CTRL to move the shown image to one of two newly created workspaces, or SHIFT to end the script.