Hi again.
Well I have emailed myself the template and here is what's happeneing.
Background is I made a template, attached a toolbar to it with 5 macro buttons. Stored the macro VBA code in 'This Workbook', attached the code to the buttons, and the toolbar to the workbook, no worries.
Here's what it's doing. Let's say I open the template, and create a document called 'test'. I save 'test', and close Excel. But later, I realise I don't need 'test', and delete it. So far so good.
BUT the next time I use 'template' and use a macro button, I get the message 'test1 (or whatever).xls could not be found. It's like the last document the macros were used in HAS to be on the computer. If it's deleted, or in my case now if I email it out, the macros cannot be found without that last document they were used in. The toolbar is programmed to open and close upon the template opening and closing, but they just don't seem to stay with the template, they go to 'doc1 based on the template', and won't work at all if 'doc 1 based on the template is deleted or emailed out or whatever. I have to reassign the macros to 'this workbook' each time, as they become assigned to 'doc1 based on the template' and so on.
I am totally stumped how these storage locations work. What is the BEST place for a macro that needs to be attached to a worksheet and mailed out as an attachment. Is it All open workbooks, Personal.xls, or this workbook. I have tried to use help for this, but unfortunately, it isn't any help at all for this.
Feedback appreciated/needed!!!!
Many thanks, Lauren
Well I have emailed myself the template and here is what's happeneing.
Background is I made a template, attached a toolbar to it with 5 macro buttons. Stored the macro VBA code in 'This Workbook', attached the code to the buttons, and the toolbar to the workbook, no worries.
Here's what it's doing. Let's say I open the template, and create a document called 'test'. I save 'test', and close Excel. But later, I realise I don't need 'test', and delete it. So far so good.
BUT the next time I use 'template' and use a macro button, I get the message 'test1 (or whatever).xls could not be found. It's like the last document the macros were used in HAS to be on the computer. If it's deleted, or in my case now if I email it out, the macros cannot be found without that last document they were used in. The toolbar is programmed to open and close upon the template opening and closing, but they just don't seem to stay with the template, they go to 'doc1 based on the template', and won't work at all if 'doc 1 based on the template is deleted or emailed out or whatever. I have to reassign the macros to 'this workbook' each time, as they become assigned to 'doc1 based on the template' and so on.
I am totally stumped how these storage locations work. What is the BEST place for a macro that needs to be attached to a worksheet and mailed out as an attachment. Is it All open workbooks, Personal.xls, or this workbook. I have tried to use help for this, but unfortunately, it isn't any help at all for this.
Feedback appreciated/needed!!!!
Many thanks, Lauren