Open A Url From A Form Button

MikeUK

Registered User.
Local time
Today, 15:34
Joined
Dec 14, 2000
Messages
36
hi

can anyone help me with some code please.

I would like to open a URL just by clicking a button within a FORM in MS ACCESS.

thanks in advance for your help

mike
 
Try using the insert hyperlink. Its on the "Insert" menu, just click on "Hyperlink". No need to write code.
 
hmmm that was simple wasnt it!

Cheers!
 
but what if there is a universal button (in the header) that if pressed goes to the url in the relevant record. Wht then? ciz thats what i is trying to do :)
 
Please give us a example of the what you are trying to achieve, what dynamic information do you pick-up form the form and does the url include quierystring to identify the record?

Simon
 
but what if there is a universal button (in the header) that if pressed goes to the url in the relevant record. Wht then? ciz thats what i is trying to do :)

In your Button's On Click event put the following code;
Code:
FollowHyperlink Me.YourControlName
YourControlName must be a control on your form (not necessarily visible) that holds a fully formed web address, if not use something like;
Code:
    If Left(Me.YourControlName, 7) = "http://" Then
        Application.FollowHyperlink Me.YourControlName
    Else
        Application.FollowHyperlink "http://" & Me.YourControlName
    End If
 

Users who are viewing this thread

Back
Top Bottom