Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- WebBrowser1.DocumentText =
- "<html><body>Search in Google:<br/>" &
- "<form method='get' action='http://www.google.com/search'>" &
- "<input type='text' name='as_q'/><br/>" &
- "<input type='submit' value='Search'/>" &
- "</form></body></html>"
- End Sub
- Dim document = WebBrowser1.Document
- If document IsNot Nothing And
- document.All("as_q") IsNot Nothing And
- String.IsNullOrEmpty(
- document.All("as_q").GetAttribute("value")) Then
- e.Cancel = True
- MsgBox("Please enter a search term.")
- End If
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement