If you have a personal.xls workbook, you can do the following:
In the VBA editor, click the + next to the Personal.xls workbook. Then double-click on "This Workbook". Now a new blank window will come up, and there will be 2 drop-downs at the top - one that says "(General)", and one that says "(Declarations)". Change the "(General)" to "Workbook". A blank function will come up named "Private Sub Workbook_Open()" -- type in your code and you're good to go. If you do not have a personal.xls workbook, you can open a blank workbook, do the steps outlined above, and then save this workbook to your XLSTART directory. It will open every time you open Excel (and since it opens, your workbook_open event will fire also).
Hope this helps,
Russell
I plan on sending this by email and I also want to use this macro for only one workbook... I just read that Excel has an Auto_Open procedure similar to Word's AutoOpen, but I can't seem to get it to work.
Any thoughts on that? That would be perfect for what I need, but it isn't running it as the workbook is opened.
Thanks again.
Jimmy D
Never mind that last one... your posting just helped me figure out the Workbook_Open procedure which seems like it will work, as long as it gets stored in the workbook and not the workstation.
Thanks for your help Russell!
Jimmy D