View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Simon Lloyd[_71_] Simon Lloyd[_71_] is offline
external usenet poster
 
Posts: 1
Default Hyperlink to document


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

Code:
--------------------
Sub GetFileName()
Dim FileName As String
FileName = Application.GetOpenFilename
ActiveSheet.Hyperlinks.Add Anchor:=Range("a1"), Address:= _
FileName, _
TextToDisplay:="What will display in Excel Goes here"
End Sub
--------------------


Ben Davis;185144 Wrote:
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.



--
Simon Lloyd

Regards,
Simon Lloyd
'The Code Cage' (http://www.thecodecage.com)
------------------------------------------------------------------------
Simon Lloyd's Profile: http://www.thecodecage.com/forumz/member.php?userid=1
View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=51144