AppInfo.platformVersion Property

Applies to TestComplete 14.91, last modified on July 20, 2021

Description

The platformVersion property returns a version number of the platform (Gecko or XULRunner).

Declaration

AppInfo.platformVersion

Read-Only Property String

Applies To

The property is applied to the following object:

Property Value

A string that holds the platform version number.

Example

The code below obtains the platform's version and posts it to the test log.

JavaScript, JScript

function AppPlatformVersion()
{
  // Launches the Firefox web browser and obtains the process
  Browsers.item(btFirefox).Run("about:blank");
  var firefox = Sys.Browser("firefox");
  // Obtains information about the application
  var AppInfo = firefox.AppInfo;
  
  // Obtains the platform's version
  // and posts it to the test log
  var pVers = AppInfo.platformVersion;
  Log.Message("Platform's version number: " + pVers);
}

Python

def AppPlatformVersion():
  # Launches the Firefox web browser and obtains the process
  Browsers.item[btFirefox].Run("about:blank")
  firefox = Sys.Browser("firefox")
  # Obtains information about the application
  AppInfo = firefox.AppInfo
  
  # Obtains the platform"s version
  # and posts it to the test log
  pVers = AppInfo.platformVersion
  Log.Message("Platform""s version number: " + pVers)

VBScript

Sub AppPlatformVersion
  ' Launches the Firefox web browser and obtains the process
  Browsers.item(btFirefox).Run("about:blank")
  Set firefox = Sys.Browser("firefox")
  ' Obtains information about the application
  Set AppInfo = firefox.AppInfo
  
  ' Obtains the platform's version
  ' and posts it to the test log
  pVers = AppInfo.platformVersion
  Log.Message("Platform's version number: " & pVers)
End Sub

DelphiScript

function AppPlatformVersion;
var firefox, AppInfo, pVers;
begin
  // Launches the Firefox web browser and obtains the process
  Browsers.item(btFirefox).Run('about:blank');
  firefox := Sys.Browser('firefox');
  // Obtains information about the application
  AppInfo := firefox.AppInfo;
  
  // Obtains the platform's version
  // and posts it to the test log
  pVers := AppInfo.platformVersion;
  Log.Message('Platform''s version number: ' + pVers);
end;

C++Script, C#Script

function AppPlatformVersion()
{
  // Launches the Firefox web browser and obtains the process
  Browsers["item"](btFirefox)["Run"]("about:blank");
  var firefox = Sys["Browser"]("firefox");
  // Obtains information about the application
  var AppInfo = firefox["AppInfo"];
  
  // Obtains the platform's version
  // and posts it to the test log
  var pVers = AppInfo["platformVersion"];
  Log["Message"]("Platform's version number: " + pVers);
}

See Also

version Property

Highlight search results