AboutGyula Gulyas Expertise I can answer most questions related to macros, worksheet functions, VBA, Office automation (calling/using other MS Office programs) and geocoding using Google Maps. I have 10 years experience using and programming in MS Excel and other office applications. I have extensive experience linking and using DLLs in Excel.
Experience Macros, worksheet functions, VBA, linking of DLLs and Office automation, geocoding using Google Maps.
TT wrote at 2007-11-07 04:30:38
I've found Excel does this by default, as long as all referenced workbooks maintain their relative positions in the folder hierarchy. I've used this technique from Excel 2000 on Windows 2000 through to Excel XP on Windows XP. Try this:
Create Book1.xls & Book2.xls and save them in Folder1 (which can be anywhere)
Set up a formula in Book2.xls that references Book1.xls, e.g =...anywhere...\Folder1\[Book1.xls]Sheet1'!$A$1
Save Book2.xls and close both workbooks
Use Windows Explorere to copy Folder1 somewhere else (rename it, even, say to Folder2)
Then open the copy of Book21.xls in Folder 2
You should see the formula with the new path i.e. =...somewhere else... \Folder2\[Book1.xls]Sheet1'!$A$1
This works across drives as well as folders. Hop e it helps some!
TT.
Baresi der Libero wrote at 2008-04-30 12:47:23
I searched very long for this, so maybe it is of interest to have it here as an aswer:
It does not like like, but Excel can easily handle relative paths in cells if you use the HYPERLINK(,) function.
Example:
two files: MySheet.xls and MyHTMLPage.html
absolute pathes:
C:WorkExcelLinkMySheet.xls
C:WorkExcelLinkhtmlMyHTMLPage.html
Insert in a cell in MySheet.xls the following contents:
=HYPERLINK("htmlMyHTMLPage.html","This is a link to MyHTMLPage")
This works well, shows the relative path in the tool-tip and if the complete contents of C:WorkExcelLink is moved to another directory, the link still works as expected.
This also works if the =HYPERLINK(...) line is imported from a text file, .csv or alike. The only confusing thing is, that the link is not shown as hyperlink (blue/purple with underline).
Nevertheless the link is working and if you select all cells with imported hyperlinks and change the font to blue with underline, the hyperlinks are shown. Surprise, surprise, even the visited links are purple now.
About Excel
This topic answers questions related to Microsoft Excel spreadsheet (or workbook) stand-alone or Mircrosoft Office Excel including Excel 2003, Excel 2007, Office 2000, and Office XP. You can get Excel help on Excel formulas(or functions), Excell macros, charting in Excel, advanced features, and the general use of Excel. This does not provide a general Excel tutorial nor the basics of using a spreadsheet. It provides specific answers to using Microsoft Excel only. If you do not see your Excel question answered in this area then please ask an Excel question here