The Password property indicates a password for a Microsoft® SQL Server™ login record.
DatabaseRole Object | SQLServer Object |
RegisteredServer Object |
object.Password [= value]
Part | Description |
---|---|
object | Expression that evaluates to an object in the Applies To list |
value | String |
Use the Password property of the DatabaseRole object to set the password for an application role. For more information about security based on application roles, see Application Security and Application Roles.
For the RegisteredServer object, the Password property provides the password used when a connection is made by using the default login.
For the SQLServer object, the Password property provides the password used for a connection made with SQL Server Authentication.
String
Read/write
HRESULT GetPassword(SQLDMO_LPBSTR pRetVal);
HRESULT SetPassword(SQLDMO_LPCSTR NewValue);
Note SQL-DMO strings are always returned as OLE BSTR objects. A C/C++ application obtains a reference to the string. The application must release the reference by using SysFreeString.