First off above my code should be Access.Application.FollowHyperlink ("
No semicolon .. I don't know how that got in there. TekTip's forum software is throwing in these semicolons so ignore them in this entire post, please.
zx6r_ryder,
Create a your html field where you store your links. Have this field on your form in a text box of some sort. Create a module... paste this and edit it for your records...
Function GotoLink()
Dim frm As Form
Set frm = Forms!frmMyForm ' replace with your form name
Dim link as TextBox
Set link = frm!txtHyperLink ' replace with your Hyperlink Textbox Name
Access.Application.FollowHyperlink (link)
End Function
Now in your form, create a button and in the OnClick event call the GotoLink function.
Private Sub MyButton_OnClick()
GotoLink
End Sub
This will change the 'link' string everytime you change records on your form.
If you want to play with this, you can use this code as well..
Sub TestLink()
Dim link As String
link = "
Access.Application.FollowHyperlink (link)
End Sub
Gives you some ideas and room to play with.
-Josh ------------------
-JPeters
Got a helpful tip for Access Users? Check out and contribute to 'How to Keep Your Databases from becoming Overwhelming!'
thread181-293590
jpeters@guidemail.com
------------------