ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   How do I open a file from a named cell? (https://www.excelbanter.com/excel-programming/362141-how-do-i-open-file-named-cell.html)

Cumberland

How do I open a file from a named cell?
 

Hi, this will be an easy one for you!

In my macro, I want to open a file based on a cell's contents.

So, if A1 contained "book1.xls", how do I open the file by referencin
the cell in the macro?

Thanks in advance

--
Cumberlan
-----------------------------------------------------------------------
Cumberland's Profile: http://www.excelforum.com/member.php...fo&userid=3344
View this thread: http://www.excelforum.com/showthread.php?threadid=54456


[email protected]

How do I open a file from a named cell?
 
workbooks.Open range("A1").value


Ardus Petus

How do I open a file from a named cell?
 
Workbooks.Open Range("A1").Text

HTH
--
AP

"Cumberland" a
écrit dans le message de news:
...

Hi, this will be an easy one for you!

In my macro, I want to open a file based on a cell's contents.

So, if A1 contained "book1.xls", how do I open the file by referencing
the cell in the macro?

Thanks in advance.


--
Cumberland
------------------------------------------------------------------------
Cumberland's Profile:
http://www.excelforum.com/member.php...o&userid=33445
View this thread: http://www.excelforum.com/showthread...hreadid=544568




Cumberland[_2_]

How do I open a file from a named cell?
 

It's OK, I've worked it out now!


--
Cumberland
------------------------------------------------------------------------
Cumberland's Profile: http://www.excelforum.com/member.php...o&userid=33445
View this thread: http://www.excelforum.com/showthread...hreadid=544568



All times are GMT +1. The time now is 10:09 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com