Home |
Search |
Today's Posts |
#2
![]() |
|||
|
|||
![]() Quote:
Put following code to your workbooks VBA-module. Sub TestSheets() Dim TblAdd As Integer Dim X As Integer TblAdd = Range("A1").Value For X = 1 To TblAdd Sheets.Add After:=Sheets(Sheets.Count) Sheets(Sheets.Count).Name = "Test" & X Next X End Sub to see the module you can do the following things : 1 ) open the workbook 2 ) press ALT + F11 3 ) if you can not see any modules there, select INSERT - MODULE 4 ) paste above 10 rows to module window and save ( CTRL + S ) 5 ) switch to the normal Excel view 6 ) put some number value to cell A1 in active sheet 7 ) press ALT + F8 and run macro named Sub TestSheets() 8 ) new worksheets should appear to the right end of worksheet tabs I hope this will help you a bit. *** |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Macros: can you copy macros from one doc to another? | Excel Discussion (Misc queries) | |||
Excel 2007 macros - how to merge 5 macros together into one | Excel Discussion (Misc queries) | |||
Macros warning always shows up, even if all macros removed | Excel Discussion (Misc queries) | |||
Macros - copying macros from one computer to another | Excel Discussion (Misc queries) | |||
Training: More on how to use macros in Excel: Recording Macros | Excel Worksheet Functions |