From Appmethod Libraries
Jump to: navigation, search

Object Pascal

function Connect(const AProfile: TTetheringProfileInfo; const AProtocolType: TTetheringProtocolType = '';  const AnAdapterType: TTetheringAdapterType = ''): Boolean; override;


virtual bool __fastcall Connect(const System::Tether::Manager::TTetheringProfileInfo &AProfile, const System::UnicodeString AProtocolType = System::UnicodeString(), const System::UnicodeString AnAdapterType = System::UnicodeString());


Type Visibility Source Unit Parent
function public
System.Tether.AppProfile TTetheringAppProfile


Establishes a connection to the specified remote profile or restarts an existing connection.

Connect loads or updates the collections of Actions and Resources, and refreshes item subscriptions due to matching profile groups.

In addition to the remote profile to connect to (<AProfile>), you may optionally specify a type of protocol (<AProtocolType>) and a type of adapter (<AnAdapterType>) to use for the connection.

See Connecting to Remote Applications Using App Tethering.


A call to Connect may raise any of the following exceptions:

Exception Exception.Message Scenarios


No available connections to <profile identifier>

You need to add a protocol and an adapter connecting to <profile identifier>

  • You specified a value for either <AProtocolType> or <AProtocolAdapter>, but not for both. You must either:
    • Leave both parameters undefined, so that Connect returns the first connection available regardless of its protocol type and adapter type.
    • Specify both <AProtocolType> and <AProtocolAdapter> to indicate a specific combination of protocol type and adapter type.

Can't find resource list for profile <profile identifier>

  • The serialized resource list from <AProfile> sent unexpected data. This may happen if the remote profile (<AProfile>) is not compatible with your local profile.

Can't connect to profile <profile identifier>

See Also