Automatically create worksheets???

hardwickj

New Member
Joined
Oct 13, 2006
Messages
1
Is it at all possible for me to have a sort of "Schema" worksheet, that when someone enters text in one of the cells, excel will create a new worksheet with the name set as the text typed in the schema worksheets cell?

If so, is it possibly to have it create a customized worksheet, sort of based off a default one?

Any help is GREATLY appreciated!!!!
 

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand

lozzablake

Well-known Member
Joined
Dec 15, 2005
Messages
818
pretty simple. You can create a macro linked to the change event of the specific sheet. Whenever that cell is altered you can create a new sheet with the name of whatever is in the cell. Alternatively you could copy an exisitng sheet and re-name it. The code below has to go in the module associated with the sheet where the name is typed.

Code:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)

    If Not Application.Intersect(Target, Range("a1")) Is Nothing Then
        Sheets("Template").Copy after:=Sheets("sheet1")  'change to reflect your sheet names
        ActiveSheet.Name = Target.Value
        
    End If

End Sub
 

Forum statistics

Threads
1,136,261
Messages
5,674,704
Members
419,520
Latest member
Jennifer4Dillon

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
Top