Hyperlink to document

B

Ben Davis

I want to create a hyperlink in my excel file that points to a specific
document. I same the master excel file to a new folder for every project I
do. The document I hyperlink to also is new for every project. How do I
automaticaly change the hyperlink to reflect the new folder / file location?
I wanted to set it up so that when I performed a "save as" on the master
document it would automatically change the hyperlink path to the new folder
location.
 
S

Simon Lloyd

You coild work with Excels built in dialogue box to get the filename

Code
-------------------
Sub GetFileName(
Dim FileName As Strin
FileName = Application.GetOpenFilenam
ActiveSheet.Hyperlinks.Add Anchor:=Range("a1"), Address:=
FileName,
TextToDisplay:="What will display in Excel Goes here
End Su
-------------------
I want to create a hyperlink in my excel file that points to a specifi
document. I same the master excel file to a new folder for ever
project
do. The document I hyperlink to also is new for every project. How do
automaticaly change the hyperlink to reflect the new folder / fil
location
I wanted to set it up so that when I performed a "save as" on th
maste
document it would automatically change the hyperlink path to the ne
folde
location

--
Simon Lloy

Regards,
Simon Lloyd
'The Code Cage' (http://www.thecodecage.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top