MCConnection Object
Versions 23.4 and later: MCConnection Object is supported only for backward compatibility. Use DLConnection Object instead.
Description
Determines property values for OpenText Functional Testing connecting to Mobile Center / UFT Mobile / Digital Lab or to a local mobile device.
For more details, see Connect to Digital Lab or local mobile devices.
Version support
The following table described the version-specific information related to this object:
Feature | Supported in versions |
---|---|
The MCConnection object | 14.51 and later |
Proxy definitions | 14.52 and later |
Local device configuration options | 14.53 and later |
Connect using access keys | 14.53 patch 1 and later |
Rebrand Mobile Center to UFT Mobile | 15.0 and later |
Rebrand UFT Mobile to Digital Lab In the rest of this topic, references to Digital Lab can be substituted with UFT Mobile if you are working with an earlier version of UFT and with UFT Mobile. | 2023 |
IMPORTANT
Changes made to the MCConnection properties take effect only in the next test run.
Therefore, if you use the Automation Object Model to change these properties during a test run, subsequent mobile steps may behave unexpectedly.
Workaround:
Change the MCConnection properties in an external script that runs UFT tests and not inside of a test.
Alternatively, if you run a test that changes the MCConnection properties, run the test again to use the new connection settings.
Public Properties
![]() | The access key used to connect to Digital Lab. |
![]() | Indicates whether to use access keys or user name and password for authentication when connecting to Digital Lab. |
![]() | The port used to connect to local devices. |
![]() | The password used to connect to Digital Lab. |
![]() | The port for the Digital Lab server you want to connect to. |
![]() | The proxy server address that is used to connect to Digital Lab. |
![]() | The proxy server port that is used to connect to Digital Lab. |
![]() | Determines the proxy type that is used to connect to Digital Lab. |
![]() | The proxy username that is used to connect to Digital Lab. |
![]() | The proxy password that is used to connect to Digital Lab. |
![]() | The Digital Lab server you want to connect to. |
![]() | Determines the Digital Lab shared space to connect to. |
![]() | Indicates whether the remote access window is displayed during the test run. |
![]() | Indicates whether proxy authentication is used for connecting to Digital Lab. |
![]() | Indicates whether to connect to Digital Lab or local devices. |
![]() | Indicates whether a proxy is used for connecting to Digital Lab. In version 14.52, the property name is UsePorxySettings. |
![]() | The username used to connect to Digital Lab. |
![]() | Indicates whether SSL is used when connecting to Digital Lab. |
![]() | The Digital Lab workspace to connect to. |
AccessKey property
Supported in versions 14.53 patch 1 and later.
The access key used to connect to Digital Lab.
Generate your access keys in the Digital Lab, as described in the Digital Lab Help Center.
Read-write property.
Syntax
Public Property AccessKey As String
AuthType property
Supported in versions 14.53 patch 1 and later.
Indicates whether to use access keys or user name and password for authentication when connecting to Digital Lab.
Read-write property.
Possible string values:
"Username Password" (default)
"Access Key"
Syntax
Public Property AuthType As String
LocalPort property
Supported in versions 14.53 and later.
The port used to connect to local devices.
Read-write property.
Syntax
Public Property LocalPort As String
Password property
The password used to connect to Digital Lab.
Read-write property.
Syntax
Public Property Password As String
Port property
The port for the Digital Lab server you want to connect to.
Read-write property.
Syntax
Public Property Port As String
ProxyAddress property
Supported in versions 14.52 and later.
The proxy server address that is used to connect to Digital Lab.
Read-write property.
Syntax
Public Property ProxyAddress As String
ProxyPort property
Supported in versions 14.52 and later.
The proxy server port that is used to connect to Digital Lab.
Read-write property.
Syntax
Public Property ProxyPort As String
ProxyType property
Supported in versions 14.52 and later.
The proxy type that is used to connect to Digital Lab.
Read-write property.
Possible string values:
HTTP Proxy, System Proxy, None
Syntax
Public Property ProxyType As String
ProxyUserName property
Supported in versions 14.52 and later.
The proxy username that is used to connect to Digital Lab.
Read-write property.
Syntax
Public Property ProxyUserName As String
ProxyPassword property
Supported in versions 14.52 and later.
The proxy password that is used to connect to Digital Lab.
Read-write property.
Syntax
Public Property ProxyPassword As String
Server property
The Digital Lab server you want to connect to.
Read-write property.
Syntax
Public Property Server As String
SharedSpace Property
The Digital Lab shared space that you want to connect to.
This option is not relevant when using access keys to authenticate the connection to Digital Lab.
Read-write property.
Syntax
Public Property SharedSpace As String
ShowRemoteWndOnRun Property
Indicates whether the remote access window is displayed during mobile test runs.
Read-write property.
Syntax
Public Property ShowRemoteWndOnRun As Bool
SpecifyAuthentication property
Supported in versions 14.52 and later.
Indicates whether proxy authentication is used for connecting to Digital Lab.
Read-write property.
Syntax
Public Property SpecifyAuthentication As Bool
Type property
Supported in versions 14.53 and later.
Indicates whether to connect to Digital Lab or local devices.
Possible string values:
"0" - Connect to Digital Lab (Default).
"1" - Connect to local mobile devices.
Read-write property.
Syntax
Public Property Type As String
UseProxySettings property
Supported in versions 14.52 and later.
Indicates whether a proxy is used for connecting to Digital Lab.
Note: In version 14.52, the property name is UsePorxySettings.
Read-write property.
Syntax
Public Property UseProxySettings As Bool
Username property
The username used to connect to Digital Lab.
Read-write property.
Syntax
Public Property Username As String
UseSSL property
Determines whether SSL is used when connecting to Digital Lab.
Read-write property.
Syntax
Public Property WorkSpace As Bool
WorkSpace Property
The Digital Lab workspace that you want to connect to.
Read-write property.
Note: When using access keys to connect to Digital Lab, you cannot select a shared workspace as the access key string includes a specific tenant ID.
Syntax
Public Property WorkSpace As String
MCConnection object examples
Connect to Digital Lab
The following code shows an example of the MCConnection object, when connecting to Digital Lab:
Dim App 'As Application Set App = CreateObject("QuickTest.Application") App.Launch App.Visible = True App.Options.MCConnection.Server = "192.168.2.3" App.Options.MCConnection.Port = "8081" App.Options.MCConnection.Username = "test1" App.Options.MCConnection.Password = "test1" App.Options.MCConnection.UseSSL = False App.Options.MCConnection.ShowRemoteWndOnRun = False App.Options.MCConnection.SharedSpace = "481309064" App.Options.MCConnection.WorkSpace = "Jason"
Connect to a local mobile device
The following code shows an example of the MCConnection object, when connecting to a local mobile device:
Dim App 'As Application Set App = CreateObject("QuickTest.Application") App.Launch App.Visible = True App.Options.MCConnection.Type= "1" App.Options.MCConnection.LocalPort = "8080"