共用方式為


IVsFindScope.GetQuery Method

Returns a query string

Namespace:  Microsoft.VisualStudio.TextManager.Interop
Assembly:  Microsoft.VisualStudio.TextManager.Interop (in Microsoft.VisualStudio.TextManager.Interop.dll)

Syntax

'宣告
Function GetQuery ( _
    <OutAttribute> ByRef pbstrBaseDirectory As String, _
    <OutAttribute> ByRef pbstrQuery As String _
) As Integer
int GetQuery(
    out string pbstrBaseDirectory,
    out string pbstrQuery
)
int GetQuery(
    [OutAttribute] String^% pbstrBaseDirectory, 
    [OutAttribute] String^% pbstrQuery
)
abstract GetQuery : 
        pbstrBaseDirectory:string byref * 
        pbstrQuery:string byref -> int 
function GetQuery(
    pbstrBaseDirectory : String, 
    pbstrQuery : String
) : int

Parameters

  • pbstrBaseDirectory
    Type: System.String%
    [out] The base directory for relative filenames. If value is nulla null reference (Nothing in Visual Basic), the Find manager's default base is used.

Return Value

Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

Implement only one of GetQuery or EnumFilenames.

COM Signature

From textfind.idl:

HRESULT IVsFindScope::GetQuery(
   [out] BSTR * pbstrBaseDirectory,
   [out,retval] BSTR * pbstrQuery
);

Relative (or unspecified) paths in the query are resolved against bstrBaseDirectory. If bstrBaseDirectory is nulla null reference (Nothing in Visual Basic), the Find manager's default base is used.

.NET Framework Security

See Also

Reference

IVsFindScope Interface

Microsoft.VisualStudio.TextManager.Interop Namespace