Convert existing worksheet to VBA code in order recreate the the identical worksheet

kkruze

New Member
Joined
Jul 23, 2016
Messages
2
I have a workbook with worksheets that include hundreds of rows and dozens of columns, fully formatted with borders, colors, formulas etc. The sheet contains both static areas and areas where users input information. What I want to know is there a way to take a sheet and copy (for lack of a better term) the underlying code or to put it another way have a spreadsheet be converted in to code that would replicate that same sheet(S).

I am not asking how to copy and paste a work sheet via vba. Nor do I want to have to record macros as a recreate a sheet, or starting coding from scratch.

Rather want to have the actual code that would result in the exact sheet being recreated once the code is run. Much appreciated
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).
Not sure that I understand what you talking about here?

If you want to replicate a sheet exactly,
right-click the tab name and select Move Or Copy
Check the Create Copy box
Select where you want the copied sheet to be (or select (to the end)
click OK

You will now have a carbon-copy of that sheet...rename if needed
 
Upvote 0
Not sure that I understand what you talking about here?

If you want to replicate a sheet exactly,
right-click the tab name and select Move Or Copy
Check the Create Copy box
Select where you want the copied sheet to be (or select (to the end)
click OK

You will now have a carbon-copy of that sheet...rename if needed


I would like vba code to create an identical sheet without having to copy the sheet and then paste the sheet. For example I want to distribute vba code that will create the sheet I have, the user would not have access to copy an existing sheet, rather they could simply run the macro. I realize I could write a module or several that could create the sheet as I have but I would rather have a process that could simply take the sheet and convert to code that would recreate the sheet, not copy and paste.

thanks
 
Upvote 0
I would like vba code to create an identical sheet without having to copy the sheet and then paste the sheet. For example I want to distribute vba code that will create the sheet I have, the user would not have access to copy an existing sheet, rather they could simply run the macro. I realize I could write a module or several that could create the sheet as I have but I would rather have a process that could simply take the sheet and convert to code that would recreate the sheet, not copy and paste.

thanks

I'm looking for exact same, ever found answer for this?
 
Upvote 0

Forum statistics

Threads
1,214,784
Messages
6,121,536
Members
449,037
Latest member
tmmotairi

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