Please Help Me! I'm Getting this error:
Error 2 C:\Users\Nick\Documents\Visual Studio 2010\Projects\HTMLGrabber\HTMLGrabber\Form1.vb 143 'System.Data.Keywords' is not accessible in this context because it is 'Friend'. 38 HTMLGrabber
My current code is:
Public Sub RichTextBox1_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RichTextBox1.TextChanged
Dim line As Integer = RichTextBox1.GetLineFromCharIndex(RichTextBox1.SelectionStart)
Dim selStart As Integer = 0
Dim selEnd As Integer = -1
Dim caret As Integer = RichTextBox1.SelectionStart
Dim ch As Char
Dim word As String
If RichTextBox1.Lines.Length <= 0 Then Exit Sub
For i As Integer = 0 To RichTextBox1.Lines(line).Length - 1
ch = RichTextBox1.Lines(line).Chars(i)
If Not Char.IsLetter(ch) Then
If selStart = -1 Then
selStart = i + 1
Else
selEnd = i
' Do selection Check
word = RichTextBox1.Lines(line).Substring(selStart, selEnd - selStart)
If Array.IndexOf(Keywords, word) <> -1 Then
RichTextBox1.Select(selStart, selEnd - selStart)
RichTextBox1.SelectionColor = Color.Blue
RichTextBox1.SelectionStart = caret
selStart = i + 1
End If
End If
End If
Next i
End Sub
End Class
Please Help!