![]() |
Using the name in a cell to open/activate a workbook
HI- How do I take the name of a workbook which resides in a cell in my current open workbook and open or activate that workbook value in the cell? I did a superficial recorded macro copying the label and pasting it into Open workbook window. However, what I really want to do is reactivate the other workbook. Problem is, I only can derive the name of that workbook from that cell in the current workbook. The reason for this confusing scenario is that we will be sending out an Excel file (we'll call it the user file) which will need to be updated from time to time. We will not know the name or the path of that file, but we have a macro in that Excel file to paste the name and path into the workbook that is called the Update file. Now we need the update file to launch it's own macro to do the necessary updating of the user file. To repeat my question: Can I take the name in the cell in the Update file and use it to reactivate the user file that is already open. Sub tempfindotherworkbook() ' ' Range("D39:E39").Select ActiveCell.FormulaR1C1 = "userfileNewVersion.xls" Selection.Copy Workbooks.Open filename:= _ "userfileNewVersion.xls" THE NAME OF THIS WORKBOOK IS VARIABLE End Sub |
All times are GMT +1. The time now is 02:17 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com