Work with complex parts : Start external programs : Example: Start Notepad

Example: Start Notepad
Start external programsStart external programsNo tip for this topicNo example for this topicTest using the Form Input CheckerTest using the Form Input Checker
Suppose you are using Windows and want to start the Notepad from a VA Smalltalk application. To effect this, do the following:
Adding a Program Starter part
Begin by adding a Program Starter part to your application:
1.
2.
3.
Specifying the program
Next, define the settings for the part:
1.
2.
a.
Select Find and, in the dialog that opens, find the path name for notepad.exe. The full path name might be C:\Program Files\WINDOWS\system32\notepad.exe. Once you find and select Notepad.exe, select OK.
b.
In the Parameter string field, specify any parameter you want passed to the editor when it starts. For example, specifying a text file and its path, such as abt.ini, opens the Notepad on the text file.
3.
Now, add a push button to your application, and connect the clicked event for the push button to the startProgram action of the Program Starter part. The Composition Editor shows the following:
Window with program starter
Run the application and select the push button. The Notepad opens on the specified file.