How do I Search a word within a richtextbox?(like a spell checker)
Remember, if someone's post was not helpful, you can always rate their post negatively .
You could use the Instr function. Code: Private Sub Command1_Click() If InStr(RichTextBox1, "Text") Then MsgBox "string found" Else MsgBox "string not found" End If End Sub Or you can use it's Find function. Code: Private Sub Command1_Click() RichTextBox1.Find "Text" RichTextBox1.SetFocus End Sub
Private Sub Command1_Click() If InStr(RichTextBox1, "Text") Then MsgBox "string found" Else MsgBox "string not found" End If End Sub
Private Sub Command1_Click() RichTextBox1.Find "Text" RichTextBox1.SetFocus End Sub
thanx ill try that
Forum Rules