Job_InstallationCompleted
Description
Section titled “Description”Completes the installation. Call it after the installation steps, before Job_End.
In attended and logoff installation mode, the function shows a message to the end user that says whether the installation succeeded or failed. The message is shown only if Job_InstallationStart informed the user when the installation started. No message is shown if the script requested a reboot with Job_RebootWS, or if the user rejected a restart.
The function also:
- Runs
CustomInstallationCompletedin Customlib, if it exists. - In computer jobs, clears the Windows logon message (the
LegalNoticeCaptionandLegalNoticeTextvalues underHKLM\Software\Microsoft\Windows NT\CurrentVersion\Winlogon). Job_InstallationStart sets this message during a logoff installation. The values are cleared in every computer job, even if they were set by something else, such as a Group Policy.
Syntax
Section titled “Syntax”Job_InstallationCompleted(sMsg, bJobStatus) As Boolean
Parameters
Section titled “Parameters”sMsg (String)
Section titled “sMsg (String)”Name of the installation to show in the message, typically the product name.
bJobStatus (Boolean)
Section titled “bJobStatus (Boolean)”The current job status, normally bStatus. It decides whether the message says the installation succeeded or failed.
Return value
Section titled “Return value”The function returns the value of bJobStatus, so you can assign the result to bStatus.
Example
Section titled “Example”bStatus = Job_InstallationCompleted("Custom", bStatus)