Open external file using a macro

zkoneffko

Registered User.
Local time
Today, 03:25
Joined
Jun 4, 2008
Messages
13
Ok. Here is what I'm trying to go. I have a field in a database that is the name of a file. In a query I formated it to a new field that included the address of where that file is on the network. The new query looks something like this: \\web01\website\images\test.jpg

Since I created the address using a queary it does not allow me to make it a hyperlink. I want to be able to click on a button in a form that reads this field and opens that file.

Is there a way to make a macro that does that?

Thanks
 
I'm an idiot

Never mind I'm an idiot. I just refered to the field in the form like this:

Private Sub Command1_Click()
Command1.HyperlinkAddress = Forms!form1.testfield
End Sub
 

Users who are viewing this thread

Back
Top Bottom