The Password property indicates a password for a Microsoft® SQL Server™ 2000 login record.
object.Password [= value]
object
Expression that evaluates to an object in the Applies To list
value
String that contains the password
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 using SysFreeString.
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 Establishing Application Security and Application Roles.
For the RegisteredServer object, the Password property provides the password used when a connection is made using the default login.
For the SQLServer object, the Password property provides the password used for a connection made with SQL Server Authentication.
For the Backup2 and Restore2 objects, the Password property provides the password used for a backup set. Password can be used in conjunction with the MediaPassword property, which provides the password for a media set. For more information, see MediaPassword Property.
Note The recommended method for connecting to an instance of SQL Server 2000 is to use Windows Authentication mode.
Note If an application calls Password on an instance of SQL Server version 7.0 or earlier with the Backup2 or Restore2 objects, the settings are ignored.