Partager via


IRTCClientProvisioning::EnableProfile (Windows CE 5.0)

Send Feedback

This method enables a profile for use in server registration and automatic profile selection.

HRESULT EnableProfile(IRTCProfile* pProfile,long lRegisterFlags);

Parameters

  • pProfile
    [in] Pointer to the profile object that is enabled.

  • lRegisterFlags
    [in] RTCRF_ constants used to specify the types of sessions that the profile should be registered for on the server.

    A value of zero will enable a profile without registering it.

    To disable registration, set this value to zero.

Return Values

This method can return an RTC_E_ constant.

The following table shows an additional possible return value.

Value Meaning
E_INVALIDARG Invalid register flags.

Remarks

The application should have only one PC-to-PC profile if it is using presence.

The first enabled PC-to-PC profile is the default presence profile for operations involving the presence store, as well as the IRTCClientPresence::AddBuddy method.

When enabling the default profile, the RTCRF_REGISTER_PRESENCE flag must be used to allow incoming watchers to be routed to the client. After the profile is enabled, the IRTCClientPresence::EnablePresence method can be called to enable the presence store.

Enabled profiles show up in the profile list retrieved by IRTCClientProvisioning::EnumerateProfiles and IRTCClientProvisioning::Profiles. They are also available to be selected for use by IRTCClient::CreateSession and IRTCClientPresence::AddBuddy.

If lRegisterFlags specifies flags, and the profile contains information about a SIP registrar server, registration occurs.

To trigger deregistration, the profile can be disabled with IRTCClientProvisioning::DisableProfile or enabled again with the lRegisterFlags parameter set to zero.

The status of registration and deregistration is notified with RTCE_REGISTRATION_STATE_CHANGE events.

If a profile is enabled with the same key value as an existing enabled profile, the existing profile is disabled and replaced by the new profile.

For information about provisioning, see the RTC Client API XML Schema.

Security Note   This method can send data over the network in unencrypted form. Therefore, someone eavesdropping on the network could read the data. Before using this method in an unencrypted session, consider the security risk of sending the data in clear text. An RTC session can be encrypted by specifying TLS in the profile used for the session. In addition, the application can use the RTCLM_NONE enumeration value of RTC_LISTEN_MODE to set the listen mode to disallow both static and dynamic.

Requirements

OS Versions: Windows CE .NET 4.0 and later.
Header: Rtccore.h, Rtccore.idl.
Link Library: Uuid.lib.

See Also

IRTCClientProvisioning | RTC Client API XML Schema | IRTCClient::CreateSession | IRTCClientPresence::AddBuddy | IRTCClientPresence::EnablePresence | IRTCClientProvisioning::DisableProfile | IRTCClientProvisioning::EnumerateProfiles | IRTCClientProvisioning::Profiles | IRTCProfile

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.