InstAPI.GetSQLInstanceRegStringByID 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
從實例特定的登錄樹中,透過給定的實例 ID、子樹及值名稱,取得登錄檔字串。
public:
static bool GetSQLInstanceRegStringByID(Microsoft::SqlServer::INST_ID ^ instanceID, System::String ^ registryPath, System::String ^ valueName, System::Text::StringBuilder ^ data, System::UInt32 % bufferSize);
public static bool GetSQLInstanceRegStringByID(Microsoft.SqlServer.INST_ID instanceID, string registryPath, string valueName, System.Text.StringBuilder data, ref uint bufferSize);
static member GetSQLInstanceRegStringByID : Microsoft.SqlServer.INST_ID * string * string * System.Text.StringBuilder * uint32 -> bool
Public Shared Function GetSQLInstanceRegStringByID (instanceID As INST_ID, registryPath As String, valueName As String, data As StringBuilder, ByRef bufferSize As UInteger) As Boolean
參數
- instanceID
- INST_ID
指向相關實例的實例 ID 指標。
- registryPath
- String
一個指向緩衝區的指標,用來接收登錄檔路徑。
- data
- StringBuilder
一個指向緩衝區的指標,用來接收將要被檢索的字串。
- bufferSize
- UInt32
一個指向 DWORD 值的指標,用以提供緩衝區的長度。 若緩衝區太小,則回傳所需長度。
傳回
true若呼叫成功;否則,。 false