Macro for Excel tabs

amattey

New Member
Joined
Jul 18, 2011
Messages
46
Hello,

Can anyone help me with a code that will copy a complete sheet including the macros within it and create another tab within the same workbook and name the sheet with the current month and year? Kinda like when I run that macro it will create a tab with the tab name for example "August, 2011" and will be an exact copy of the original sheet including its macros.
 
Yes, like that. I had something similar but was missing a command. Now my excel document seems to have such a large size. It is 10MB but I only have one sheet with like 3 macros. Is there any way to check why is it so big and fix it?
 
Upvote 0

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).
I tend not to look at the size of my workbooks too closely unless they have speed or response problems. I'm aware that others have discussed this topic on the forum so I suggest you do a search and see if you can find anything.

You could try this in a copy of your workbook: create a new worksheet, select the part of your original sheet which has the data in it, and copy that to your new sheet, then delete the original sheet. Repeat for as many sheets as you have in the workbook, then save and close the workbook. That might make a difference.
 
Upvote 0
I wrote a macro to filter data, but I am stuck on how to keep writing so I can only copy certain columns but just the filtered data. Do you think you can help here? I know I've been asking millions questions but still getting used to the VBA writing.
 
Upvote 0
I've never really used filters. Try searching the forum to see if there's any useful info and failing that, start a new thread asking for assistance.
 
Upvote 0

Forum statistics

Threads
1,225,156
Messages
6,183,244
Members
453,152
Latest member
ChrisMd

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