The Execute function launches the file if it's an executable or opens it with the default application associated.
Syntax
Integer Disk.Execute(
String path,
String args = "",
Integer wait = false,
Integer chgCurdir = false,
Integer show = true)
String path,
String args = "",
Integer wait = false,
Integer chgCurdir = false,
Integer show = true)
Parameters
| path | Pathname of the file. | Required |
|---|---|---|
| args | Arguments. | Optional |
| wait true, false | Wait while the file is running. | Optional |
| chgCurdir true, false | Set the file pathname as the current folder. | Optional |
| show true, false | Specify how an application is to be displayed when it is opened, visible or hidden. It is up to the application to decide how to handle it. | Optional |
Return value
The Execute function returns true.
If an error occurs, the Execute function returns false.
Example
myDisk.Execute("c:\game.exe")