Partilhar via


Método IVsExpansionFunction.GetCurrentValue

Retorna o valor atual da função de expansão.

Namespace:  Microsoft.VisualStudio.TextManager.Interop
Assembly:  Microsoft.VisualStudio.TextManager.Interop.8.0 (em Microsoft.VisualStudio.TextManager.Interop.8.0.dll)

Sintaxe

'Declaração
Function GetCurrentValue ( _
    <OutAttribute> ByRef bstrValue As String, _
    <OutAttribute> ByRef fHasCurrentValue As Integer _
) As Integer
int GetCurrentValue(
    out string bstrValue,
    out int fHasCurrentValue
)
int GetCurrentValue(
    [OutAttribute] String^% bstrValue, 
    [OutAttribute] int% fHasCurrentValue
)
abstract GetCurrentValue : 
        bstrValue:string byref * 
        fHasCurrentValue:int byref -> int
function GetCurrentValue(
    bstrValue : String, 
    fHasCurrentValue : int
) : int

Parâmetros

  • bstrValue
    Tipo: String%

    [out] Retorna um string que contém o valor da função de expansão.

  • fHasCurrentValue
    Tipo: Int32%

    [out] Retorna diferente de zero (true) se a função de expansão possui um valor atual; Caso contrário, retorna zero (true). Consulte Comentários.

Valor de retorno

Tipo: Int32
Se o método for bem-sucedido, ele retorna S_OK.Se ele falhar, ele retorna um código de erro.

Comentários

COM assinatura

De textmgr2.idl:

bool IVsExpansionFunction::GetCurrentValue(
   [out] BSTR *bstrValue,
   [out] bool *fHasCurrentValue
);

Se esse método retorna um valor, ele é colocado no campo associado do trecho de código inserido. Se esse método não retornar um valor, conforme indicado, definindo a fHasCurrentValue parâmetro como zero (false), a função de expansão indica que ela tenha nenhum valor atual para retornar. O fhasCurrentValue parâmetro normalmente é usado pelo chamador desse método para determinar se deve atualizar o campo no trecho de código.

Segurança do .NET Framework

Consulte também

Referência

IVsExpansionFunction Interface

Namespace Microsoft.VisualStudio.TextManager.Interop