Please enable JavaScript to view this site.

QPR Knowledge Base 2019.1

Navigation: Developer's Guide > QPR API > The Object Model > QPR Metrics > SCApplication Commands

SetUIMode

Scroll Prev Top Next More

Revision history:

Introduced in QPR 7.2.1

 

Hide/show QPR Metrics client's user interface. If UI is hidden, then all confirmation messages are defaulted to OK, which means, for instance, that objects or even a whole model can be deleted without any confirmations. If UI is hidden, then messages that require user to select some options return an error and the operation fails. UI is set to normal automatically after the script's execution ends.

 

Synopsis:

 

SCApplication.SetUIMode(Mode)

 

Parameters:

 

Mode: Integer, either 0 (UI_SILENT) or 1 (UI_NORMAL)

 

Required Rights:

 

None.

 

Return Values:

 

None.

 

Example Procedure:

 

Sub SetSilentMode()

 Dim iResult

 iResult = SCApplication.SetUIMode(0)

 If (iResult <> 0) Then

   MsgBox "Could not set silent UI mode: " + SCApplication.GetErrorMessage(iResult)

 End If

End Sub