Command Button opens website using text from textbox

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ObiBenKenobi

    #1

    Command Button opens website using text from textbox

    Hi there,

    I would like to know how to create an event procedure for a command button that uses the text of a textbox to go to a specified website.

    Example: User types "google" in a textbox, hits command button, and a web browser opens http://www.google.com.



    Any help would be appreciated. Thanks!
  • ObiBenKenobi

    #2
    Sorry, I'm a noob. This question is for MS Access 2007.

    Please let me know if more information or detail is required

    Comment

    • NeoPa
      Recognized Expert Moderator MVP
      • Oct 2006
      • 32669

      #3
      Tell us if this (How to Programmaticall y Create a Hyperlink on a Form) helps.

      Comment

      • mshmyob
        Recognized Expert Contributor
        • Jan 2008
        • 903

        #4
        Put this is the ON Click event of your button

        Code:
        Dim strURL As String
        strURL = Me.txtWeb.Text ' the string in your text box is picked up here
        Application.FollowHyperlink strURL
        cheers

        Comment

        Working...