Web browser part 2


So now isnt it annoying to press enter on your new browser and nothing happens well now you can with this code
VB Code
  1. Private Sub cburl_KeyDown(KeyCode As Integer, Shift As Integer)
  2. If KeyCode = vbKeyReturn Then
  3. web.Navigate cburl.Text
  4. End If
  5. End Sub


What about a google search???
Create a textbox (gsearch) and a buttom (cmdgoogle)
VB Code
  1. Private Sub cmdgoogle_Click()
  2. web.Navigate "https://www.google.com/search?hl=en&q="+ gsearch + "&btnG=Google+Search"
  3. cburl.Text = "https://www.google.com/search?hl=en&q="+ gsearch + "&btnG=Google+Search"
  4. End Sub


Now a yahoo search
So a text box (ysearch) and a button (cmdyahoo)

VB Code
  1. Private Sub cmdyahoo_Click()
  2. web.Navigate "https://search.yahoo.com/search?fr=slv2-&ei=UTF-8&p=" +
  3. cburl.Text = "https://search.yahoo.com/search?fr=slv2-&ei=UTF-8&p=" + ysearch
  4. End Sub


Maybe some more to come but thats all for now folks!
MOD-Dan's Avatar
Author:
Views:
2,468
Rating:
Posted on Thursday 12th July 2007 at 06:08 PM
FtH8er
FtH8er's Avatar
anywhere on your layout, if u are talkin about the design part, or if u are talkin bout the code part it doesnt matter where u put it.
Posted on Thursday 12th July 2007 at 05:57 PM
vb_king
vb_king's Avatar
no i mean the google thing, when i put the code in where do i put the button and text box? O_O
Posted on Thursday 12th July 2007 at 05:41 PM
MOD-Dan
MOD-Dan's Avatar
anywhere in your code
Posted on Thursday 12th July 2007 at 05:11 PM
vb_king
vb_king's Avatar
but where are we supposed to put this? O_O