Start Method (SQLServer) (SQL-DMO)

The Start method starts the Microsoft® SQL Server™ service, optionally connecting the SQLServer object on successful start.

Applies To

SQLServer Object

Syntax

object.Start( StartMode , [ Server ] , [ Login ] , [ Password ] )

Part Description
object Expression that evaluates to an object in the Applies To list.
StartMode When True, an attempt is made to connect on successful start. When False, no attempt is made to connect after successful start.
Server Optional. A string specifying the SQL Server installation started by name.
Login Optional. A string specifying a SQL Server login used when an attempt is made to connect after successful start (StartMode is True).
Password Optional. A string specifying a SQL Server password used for login validation when an attempt is made to connect after successful start (StartMode is True).

Remarks

The Start method can only be used on a SQLServer object not connected to a SQL Server installation.

Specify the SQL Server service to start by using the Name property of the SQLServer object, or the optional Server argument of the Start method. Using the Server argument overrides any previous specification made by using the Name property.

Prototype (C/C++)

HRESULT Start(
BOOL fConnect,
SQLDMO_LPCSTR Server = NULL,
SQLDMO_LPCSTR Login = NULL,
SQLDMO_LPCSTR Password = NULL);

  


(c) 1988-98 Microsoft Corporation. All Rights Reserved.