Metodo EditPoint2.WordRight (Int32)
Sposta l'oggetto il numero specificato delle parole a destra.
Spazio dei nomi: EnvDTE80
Assembly: EnvDTE80 (in EnvDTE80.dll)
Sintassi
'Dichiarazione
Sub WordRight ( _
Count As Integer _
)
void WordRight(
int Count
)
void WordRight(
[InAttribute] int Count
)
abstract WordRight :
Count:int -> unit
function WordRight(
Count : int
)
Parametri
- Count
Tipo: System.Int32
facoltativo.Quante parole per spostare il punto di modifica a destra della posizione corrente nel buffer.
Note
Se la fine del documento viene raggiunta prima Count le parole, il punto rimane alla fine del documento.
Se l'argomento è negativo, quindi WordRight esegue lo stesso modo di WordLeft.
Esempi
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
Sicurezza di .NET Framework
- Attendibilità totale per il chiamante immediato. Impossibile utilizzare questo membro in codice parzialmente attendibile. Per ulteriori informazioni, vedere Utilizzo di librerie da codice parzialmente attendibile.