|
|
|
|
Functions
Events
MioScript Reference
|
|
Syntax
| app.install(appName, appId, targetFolder, addInProgram, autoStart, desktop, allUsers) |
Parameters
| STRING | appName | Application Name. You should use the string {APP_NAME} as shown in the sample below.
| | STRING | appId | Application ID. You should use the string {APP_ID} as shown in the sample below.
| | STRING | targetFolder | Folder where to install the application. To install the application in Program Files: path.programFiles.
| | BOOL | addInProgram | Optional. Default is null. If set to true, a shortcut is added in All Programs. If set to false, the shortcut, if any, is removed from All Programs. Set to null for no action.
| | BOOL | autoStart | Optional. Default is null. If set to true, the application will run when the computer starts. If set to false, the shortcut, if any, is removed from All Programs. Set to null for no action. More info: {APP_OPENATSTARTUP}.
| | BOOL | desktop | Optional. Default is null. If set to true, a shortcut is added on the desktop. If set to false, the shortcut, if any, is removed from All Programs. Set to null for no action.
| | BOOL | allUsers | Optional. Default is false: the shortcuts are added for the current user. If set to true, shortcuts are added to all users. |
Return value
No value is returned.
Description
Installs the application on the local computer at the specified location.
In most of the cases, the application is installed by the installer, so the user is informed about the process and can change the default settings.
Use a silent install only if you deploy the application through your intranet.
Warning: This function should not be called directly except if you are sure the application have full admin rights.
In order to enable the install, the application must be published as an EXE file with no installer.
When the exe file is executed, the function installs the application and restarts it from the definitive location.
If the parameter addInProgram is set to true, a shortcut is added in the All Programs folder. The name of the sub-folder is the application name.
If the parameter autoStart is set to true, a shortcut is added in the Startup folder, so the application will run when the computer starts.
The call to this function should be done just after the call to app.init.
Important: The installation is not processed immedialty after the call of the function. |
MioScript Sample Code
app.install("{APP_NAME}", "{APP_ID}", path.programFiles("{APP_NAME}")) |
|
|
|