Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The example below shows how this function could be used in a real world situation. The CompliancyCheck function could be included in the package itself or provided via CustomLib.cis and will prevent a package from running on 64 bit OS in this case.

 


Syntax

CMS_SetPackageStatusToNotCompliant() as Boolean 


Example

Code Block
language
languagevb
themeEclipse
vbtitleVBScript
Function CompliancyCheck()
  Dim bStatus : bStatus = True
  If gbx64 Then
    If bStatus Then bStatus = Job_WriteLog("CompliancyCheck", "Package is not allowed to run on 64 bit OS", bStatus, True)
    If bStatus Then bStatus = CMS_SetPackageStatusToNotCompliant()
  End If
  CompliancyCheck = bStatus
End Function

Scripting Guidelines 


Related functions