Partager via


IMsTscNonScriptable::put_PortablePassword (Windows Embedded CE 6.0)

1/6/2010

This method sets the password part of a connection password for the Remote Desktop ActiveX control in portable encoded format.

Syntax

HRESULT put_PortablePassword(
  BSTR newPortablePassVal
);

Parameters

  • newPortablePassVal
    [in] Connection password, specified in portable-encoded format.

Return Value

The following table shows the return values for this method.

Value Description

S_OK

Password was correctly set.

E_FAIL

The control is already connected or in the connecting state.

nonzero error code

An error occurred.

Remarks

You can also call this method to specify the password part of a connection password after you first call put_ClearTextPassword and then get_PortablePassword to convert the password.

To set a password in portable-encoded format, you must call both put_PortablePassword and put_PortableSalt.

A portable encoded password consists of an encoded portable password and an encoded portable salt value. Portable encoded passwords should not be considered strongly encrypted. Portable encoded passwords can be transferred to other users on other computers.

To enable automatic logon, you must also set the UserName, Domain, and PortableSalt properties. If the password fails to authenticate the user, the Windows logon dialog box is displayed at the server to prompt the user for the password.

This property can be set only if the control is not in the connected state. The method returns E_FAIL if called when the control is connected. You can check if the control is connected by calling the IMsTscAx::get_Connected method.

Requirements

Header discodlg.h, mstsax.idl
Library Mstsax.lib
Windows Embedded CE Windows CE .NET 4.0 and later

See Also

Reference

IMsTscNonScriptable
IMsTscNonScriptable::get_PortablePassword