IVsTextImage.Replace, méthode

Notification d'un remplacement d'étendue de texte.

Espace de noms :  Microsoft.VisualStudio.TextManager.Interop
Assembly :  Microsoft.VisualStudio.TextManager.Interop (dans Microsoft.VisualStudio.TextManager.Interop.dll)

Syntaxe

'Déclaration
Function Replace ( _
    dwFlags As UInteger, _
    pts As TextSpan(), _
    cch As Integer, _
    pchText As String, _
    <OutAttribute> ptsChanged As TextSpan() _
) As Integer
int Replace(
    uint dwFlags,
    TextSpan[] pts,
    int cch,
    string pchText,
    TextSpan[] ptsChanged
)
int Replace(
    [InAttribute] unsigned int dwFlags, 
    [InAttribute] array<TextSpan>^ pts, 
    [InAttribute] int cch, 
    [InAttribute] String^ pchText, 
    [OutAttribute] array<TextSpan>^ ptsChanged
)
abstract Replace : 
        dwFlags:uint32 * 
        pts:TextSpan[] * 
        cch:int * 
        pchText:string * 
        ptsChanged:TextSpan[] byref -> int
function Replace(
    dwFlags : uint, 
    pts : TextSpan[], 
    cch : int, 
    pchText : String, 
    ptsChanged : TextSpan[]
) : int

Paramètres

  • dwFlags
    Type : UInt32

    [in] double mot contenant des balises. Pour une utilisation ultérieure. Ensemble à zéro.

  • cch
    Type : Int32

    [in] nombre de personnages dans pchText.

  • pchText
    Type : String

    [in] pointeur à une chaîne de texte.

Valeur de retour

Type : Int32
Si la méthode réussit, elle retourne S_OK.En cas d'échec, un code d'erreur est retourné.

Notes

L'environnement appellera IVsTextImage.Replace pour vous avertir d'une opération de remplacement effectuée sur une étendue de texte. Retournez la nouvelle étendue de texte à l'environnement.

Signature de COM

De textmgr.idl :

HRESULT IVsTextImage::Replace(
   [in] DWORD dwFlags,
   [in] const TextSpan * pts,
   [in] LONG cch,
   [in, size_is(cch)] LPCOLESTR pchText,
   [out, retval] TextSpan * ptsChanged
);

Sécurité .NET Framework

Voir aussi

Référence

IVsTextImage Interface

Microsoft.VisualStudio.TextManager.Interop, espace de noms