Hello,
I need help. I'm trying to set 3 different files as "workbook objects" and switch between the 3 in the code. A few times it worked (can't remember what I did) and more times than not it's doing weird things. My working with workbook objects has been very limited.
I think my initial problem is where I'm prompting the user to open a file and it never gets "set" to the workbook object name. Maybe if that would work, the rest of the code would? (Note: I'm only working with 2 workbooks here, I have 3 more to add later in the code so I need to get this right in my head now.)
In addition, I am including code below that works up until a point (only in Excel 2010, not 365) when I want to close the one workbook I'm done with. When I run those two lines of code to .activate and then .close, it closes my Add-in! (named Piledriver.xlsm which is never referenced in the code) Why??
And can you tell me when you would use "Close workbookname" rather than "workbook.close" ?
Thank you so much for your help!
PatB
Bookmarks