Opening a File with a Cell Reference in ExcelLast reviewed: November 2, 1994Article ID: Q34155 |
The information in this article applies to:
SUMMARYTo select a cell that contains a certain filename in a macro and have the macro automatically open the file that is listed in the selected cell, use the following macro line:
=OPEN(DEREF(cell reference))The OPEN command requires that a full path be included to the file that is to be opened. Therefore, if the file is not in the current directory, you must include a complete path to the file that is listed in the cell of the worksheet. The following are examples:
MORE INFORMATIONIt is recommended to include the complete path as noted in Example 2 in all cases. Include the following in the macro:
=OPEN(DEREF(sheet1!$A$1)) |
KBCategory: kbusage
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |