InstAPI.GetSQLDataRootByInstName(String, StringBuilder, UInt32) Method

Definition

Retrieves the SQL data file root directory by the given friendly instance name.

public:
 static bool GetSQLDataRootByInstName(System::String ^ instanceName, System::Text::StringBuilder ^ directoryPath, System::UInt32 % bufferSize);
public static bool GetSQLDataRootByInstName (string instanceName, System.Text.StringBuilder directoryPath, ref uint bufferSize);
static member GetSQLDataRootByInstName : string * System.Text.StringBuilder * uint32 -> bool
Public Shared Function GetSQLDataRootByInstName (instanceName As String, directoryPath As StringBuilder, ByRef bufferSize As UInteger) As Boolean

Parameters

instanceName
String

A String value that represents the instance name.

directoryPath
StringBuilder

A pointer to a buffer to receive the path.

bufferSize
UInt32

A pointer to a DWORD value to supply the length of the buffer. Returns the required length if the supplied buffer is too small.

Returns

true if the call succeeded; otherwise, false.

Applies to