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. Open a Composition Editor on the visual part from which you want to start the editor.
2. Select External Functions category icon (External Functions category) and then Program Starter icon (Program Starter part).
3. Click on the free-form surface.
Specifying the program  
Next, define the settings for the part:
1. Open the Program Starter part's settings.
2. Change the settings as follows:
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. Select OK.
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.
Last modified date: 08/14/2019