+ Reply to Thread
Results 1 to 4 of 4

Thread: Basic Browser.

  1. #1
    Paradox is offline Newbie
    Join Date
    Jul 2008
    Posts
    17
    Rep Power
    16

    Basic Browser.

    Here is what you need.
    * 5 Buttons
    * 1 Webbrowser
    * 2 Textbox


    Code:
    Public Class Form1
        Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
            WebBrowser1.GoForward()
        End Sub
    
        Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
            WebBrowser1.GoBack()
        End Sub
    
        Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
            WebBrowser1.Navigate(Texbox1.Text)
        End Sub
    
        Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
            WebBrowser1.Refresh()
        End Sub
    
        Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
            WebBrowser1.Navigate("http://www.google.com/search?hl=en&q=" + Texbox2.Text)
        End Sub
    End Class

  2. CODECALL Circuit advertisement
    Join Date
    Always
    Posts
    Many

     
  3. #2
    Join Date
    Jul 2008
    Location
    Somewhere that is shorter to write than "In the gloomy shadows of my personal namespace"
    Posts
    10,725
    Blog Entries
    2
    Rep Power
    90

    Re: Basic Browser.

    Very little code...! VB is compact...
    Hey! Check out my new Toyota keyboaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

  4. #3
    Join Date
    Aug 2006
    Posts
    11,209
    Blog Entries
    6
    Rep Power
    101

    Re: Basic Browser.

    Great tutorial. Thanks for your contribution!

    Posts moved here:
    Browser or Wrapper?

  5. #4
    Umbrageous's Avatar
    Umbrageous is offline Newbie
    Join Date
    Oct 2008
    Location
    Undernet
    Posts
    17
    Rep Power
    0

    Re: Basic Browser.

    Hmm, Yeah its simple, but only works for vb6 My Code because i use vB 2005 and the browser i made uses tabs looks more like this
    Private Sub ToolStripButton4_Click(ByVal sender As System.Object, ByVal e As

    Code:
    System.EventArgs) Handles ToolStripButton4.Click
            CType(TabControl1.SelectedTab.Controls.Item(0), WebBrowser).Refresh()
        End Sub
    
        Private Sub ToolStripButton5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ToolStripButton5.Click
            CType(TabControl1.SelectedTab.Controls.Item(0), WebBrowser).Stop()
        End Sub
    
        Private Sub ToolStripButton6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ToolStripButton6.Click
            CType(TabControl1.SelectedTab.Controls.Item(0), WebBrowser).GoHome()
        End Sub
        Friend WithEvents ToolStripButton7 As System.Windows.Forms.ToolStripButton
    
        Private Sub ToolStripButton7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ToolStripButton7.Click
            CType(TabControl1.SelectedTab.Controls.Item(0), WebBrowser).Navigate("Can't post Links...." & ToolStripTextBox2.Text)
        End Sub

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 3
    Last Post: 05-05-2011, 09:12 PM
  2. Replies: 4
    Last Post: 02-20-2011, 04:18 PM
  3. Replies: 0
    Last Post: 07-13-2010, 06:43 PM
  4. Visual Basic 2008 vs. Visual Basic 2005 - Compatibility
    By cande_300 in forum Visual Basic Programming
    Replies: 1
    Last Post: 01-23-2010, 09:00 AM
  5. Basic JFrame with a basic JButton.
    By Paradox in forum Java Tutorials
    Replies: 0
    Last Post: 07-18-2008, 08:46 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts