InstAPI.GetSQLToolsDirPath(StringBuilder, UInt32) 方法

定義

取得 SQL Server 工具安裝的目錄根目錄。

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

參數

directoryPath
StringBuilder

一個指向緩衝區的指標,用來接收登錄檔路徑。

bufferSize
UInt32

一個指向 DWORD 值的指標,用以提供緩衝區的長度。 若緩衝區太小,則回傳所需長度。

傳回

若呼叫成功,則回傳 TRUE;若呼叫失敗,則回傳 FALSE。

備註

請注意,每個 SQL Server 版本只有一個工具安裝,而不是每個實例安裝一個工具。

適用於