Dans System.Windows.Forms.RichTextBox, comment convertir un numéro de ligne en position de caractère?

StackOverflow https://stackoverflow.com/questions/1434660

  •  07-07-2019
  •  | 
  •  

Question

Je voudrais la conversation de RichTextBox.GetLineFromCharIndex ()

J'ai un numéro de ligne et je souhaite récupérer l'index de caractères pour cette ligne. La méthode peut être appelée RichTextBox.GetCharIndexFromLine () .

Est-ce possible, simplement?

Était-ce utile?

La solution

richTextBox1.GetFirstCharIndexFromLine(int lineNumber)

Autres conseils

Oui, la méthode est RichTextBox.GetFirstCharIndexFromLine (LineNumber)

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top