Promotic
WikipediaLinkedInYoutubeTwitterFacebook

ClientType - property of object PmiRoot

Description:
It gets whether the window is opened in PROMOTIC application or in WEB browser.
Syntax:
ClientType As Integer
Calling:
nType = oRoot.ClientType
Values:
1 - Window is opened in PROMOTIC application
2 - Window is opened in WEB browser
Note:
Property access for read only.

By this property it is possible to conditionally run different algorithms in the application and in the WEB browser. It is relevant only if the panel is used locally in the application and also for WEB as Web Panels (i.e. if the WEB sharing is enabled in the Web Server page).

 
This property is also functional for Web Panels.
Example:
Example for JavaScript language:
if(pMe.Root.ClientType == 1)
{
  ' algorithm for local panel
}
else if(pMe.Root.ClientType == 2)
{
  ' algorithm for WEB
}
Example for VBScript language:
If pMe.Root.ClientType = 1 Then
  ' algorithm for local panel
ElseIf pMe.Root.ClientType = 2 Then
  ' algorithm for WEB
End If
© MICROSYS, spol. s r. o.Tavičská 845/21 703 00 Ostrava-Vítkovice