I have a column like this
ID
1100
1101
1102
1103
.
.
.
1299
and I would like to make a tabbed worksheet for each entry with its ID instead of making this manually which takes ages
Hi mammut89,
Use the next macro to insert the sheets. The macro assumes the sheetnames are in range B.
Success,Sub InsertSheets() Dim vCell As Variant i = Cells(Cells.Rows.Count, "B").End(xlUp).Row For Each vCell In Range("B1:B" & i) Sheets.Add.Name = vCell.Value Next vCell End Sub
Erik
excellent!
thanks mate
hm.. I have to do one last thing . and that is to put each row into the belonging ID tabed worksheet
I think I have to solve this with VBA too and im not so good at it.
thought I could solve it easier.
Last edited by mammut89; 07-04-2008 at 07:10 AM.
Maybe like this:
Sub InsertSheets() Dim cell As Range For Each cell In Range("A2", Cells(Rows.Count, "A").End(xlUp)) Sheets.Add After:=Sheets(Sheets.Count) ActiveSheet.Name = cell.Value cell.EntireRow.Copy Range("A1") Next cell End Sub
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks