Public Sub UpdateStatusBar() Dim index As Integer = TextBox1.SelectionStart Dim currentLine As Integer = TextBox1.GetLineFromCharIndex(index) Dim currentColumn As Integer = index - TextBox1.GetFirstCharIndexFromLine(currentLine) tss1.Text = "Line " + (currentLine + 1).ToString + ", column " + (currentColumn + 1).ToString End Sub
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)