Home |
Search |
Today's Posts |
#1
|
|||
|
|||
Desperately seeking ACTIVE.WORKBOOK function for XLM
I'm trying to push the name of the document where I start running a macro so I can get back there after activating a master document to which I'm copying data.
I'm programming in XLM which is a lot like worksheet functions so I'm hoping maybe this is a place where this kind of question might be welcomed. I have gotten responses elsewhere on visual basic solutions, but I'm way down the rabbit hole in XLM already. e.g. http://www.mrexcel.com/forum/showthr...34#post2619834 So I have tried using the ACTIVE.CELL function that, according to my Excel 2.2. manual, returns a cell reference with a workbook name as a prefix (or worksheet name, not sure which) but I can't get the evaluate tool to return that reference although I can use ACTIVE.CELL in formulas such as by selecting a cell and then making a call like: Code:
=IF(ACTIVE.CELL100,"true value","false value") Code:
A 154 =ACTIVE.CELL() . . . 166 =ACTIVATE(A154) They obviously knew that was the more universal reference because there is a DOCUMENTS() function, but that returns an alpha list of open documents, i.e. workbooks, without any indication of what is the active workbook. And I don't seem to find any THIS.DOCUMENT() or ACTIVE.DOCUMENT() function for returning the active workbook name. There is an ACTIVATE.PREV() command, but that, unfortunately doesn't take you to the previously active document but to the previous document in the list under the WINDOW menu. Once I find the function I'm looking for, then there is the problem of calling it. Normally you would put a name in quotes inside the function, e.g. ACTIVATE("pushedworkbook.xls") , but when you have stored the name in a Macro cell by hopefully some function that someone can identify for me, do you call it with an unquoted cell reference to the macro, e.g. ACTIVATE(A154). |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Active Workbook | Excel Discussion (Misc queries) | |||
Seeking Improvement on excel function | New Users to Excel | |||
Desperately Seeking Offset Formula!! | Excel Discussion (Misc queries) | |||
Active Workbook online. | Excel Discussion (Misc queries) | |||
copy worksheet from closed workbook to active workbook using vba | Excel Worksheet Functions |