Compartir a través de


EditPoint2.WordRight (Método)

Mueve el objeto hacia la derecha el número de palabras especificado.

Espacio de nombres:  EnvDTE80
Ensamblado:  EnvDTE80 (en EnvDTE80.dll)

Sintaxis

'Declaración
Sub WordRight ( _
    Count As Integer _
)
void WordRight(
    int Count
)
void WordRight(
    [InAttribute] int Count
)
abstract WordRight : 
        Count:int -> unit
function WordRight(
    Count : int
)

Parámetros

  • Count
    Tipo: Int32

    Opcional. Especifica el número de palabras que se desplazará el punto de edición hacia la derecha de su posición actual en el búfer.

Comentarios

Si se llega al final del documento antes de contabilizarse el número de palabras indicado en el parámetro Count, el punto permanecerá al final del documento.

Si el argumento es negativo, WordRight se comporta de forma similar a WordLeft.

Ejemplos

Sub WordRightExample()
   Dim objTextDoc As TextDocument
   Dim objEditPt As EditPoint, iCtr As Integer
        
   ' Create a new text file.
   DTE.ItemOperations.NewFile("General\Text File")
       
   ' Get a handle to the new document and create an EditPoint.
   objTextDoc = DTE.ActiveDocument.Object("TextDocument")
   objEditPt = objTextDoc.StartPoint.CreateEditPoint
        
   ' Insert ten lines of text.
   For iCtr = 1 To 10
     objeditpt.Insert("This is a test." & Chr(13))
   Next iCtr
       
   ' Replace the eighth word on the third line with a new word.
   objEditPt.StartOfDocument()
   objEditPt.LineDown(3)
   objEditPt.WordRight(3)
   objEditPt.Delete(4)
   objEditPt.Insert("raid")
End Sub

Seguridad de .NET Framework

Vea también

Referencia

EditPoint2 Interfaz

EnvDTE80 (Espacio de nombres)