Calling Macros for whole worksheet from personal.xlsb

B-Man

Board Regular
Joined
Dec 29, 2012
Messages
183
Office Version
  1. 2019
Platform
  1. Windows
I currently have a personal.xlsb that opens whenever I open excel and was wondering if i had all my macro set in there and then just called them from the worksheet.
Is that a good idea? are there any cons to this?

Currently I have a master file that I open and when it saves its saved as a new file so if I edit a macro its only changing it for the master and any new file I have created... Not a big issues as normally its only keeping the older files as record keeping but sometimes the last few are still current. but sometimes i edit something and it breaks a macro and i might have 3 or 4 files that are current so I have to solve the issue and then update it into each of the files that are currently still active.
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
I currently have a C that opens whenever I open excel and was wondering if i had all my macro set in there and then just called them from the worksheet.
Is that a good idea? are there any cons to this?

In theory, you could do that, but only for standard macros, not event code, or userform code. You might have to tighten up your code to make sure there are no unqualified range, sheet, or cell references, but it should work. However, the personal macro workbook (personal.xlsb ) is for macros that only you can run. If you are going to send a workbook to someone else and want them to be able to run a macro, then the personal macro workbook does not work for that. And if you ever change PCs you need to make sure personal.xlsb gets copied over. Then there is the all-your-eggs-in-one-basket problem. If personal.xlsb contains mission-critical code, you will need to be sure you have backups.

Currently I have a master file that I open and when it saves its saved as a new file so if I edit a macro its only changing it for the master and any new file I have created... Not a big issues as normally its only keeping the older files as record keeping but sometimes the last few are still current. but sometimes i edit something and it breaks a macro and i might have 3 or 4 files that are current so I have to solve the issue and then update it into each of the files that are currently still active

The other approach you could consider is to create an add-in (.xlam) and have your code live there. That might help with the code update problem. But if it is only 3 or 4 files, then importing a new code module with the changes does not sound too bad.
 
Upvote 0
Its only for me so no problem on the sharing of workbook. And I have it backed up in google drive.

I do use userforms so that makes it more tricky.

Sounds like what I currently do is probably best choice for the moment.

Cheers
 
Upvote 0

Forum statistics

Threads
1,215,069
Messages
6,122,956
Members
449,096
Latest member
Anshu121

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top