Related:
- Excel macro create new sheet copy & paste cells
- How to copy data from one excel sheet to another - Guide
- Excel online macros - Guide
- Windows network commands cheat sheet - Guide
- Sheet right to left in google sheet - Guide
- Excel macro to create new sheet based on value in cells - Guide
1 response
Hi,
How many rows in Column "A"?
Warning, because Excel has limited Sheets's count to 255 max.
Is there duplicates in your column "A"?
Try this with a few data in column "A", this code is the first part of your question :
to create a new sheets with colum A name
If all is well for you, we will continue with the second part : copy row cells to the new sheet
How many rows in Column "A"?
Warning, because Excel has limited Sheets's count to 255 max.
Is there duplicates in your column "A"?
Try this with a few data in column "A", this code is the first part of your question :
to create a new sheets with colum A name
Option Explicit Sub CreateNewSheets() Dim LastRow As Long, lngRow As Long Application.ScreenUpdating = False With Sheets("Feuil1") '------------> ADAPT with your Sheets's name LastRow = .Range("A" & Rows.Count).End(xlUp).Row For lngRow = 2 To LastRow '-----> Start Row = 2 If Exist_Sheet(CStr(.Cells(lngRow, 1).Value)) = False Then ThisWorkbook.Sheets.Add ActiveSheet.Name = CStr(.Cells(lngRow, 1).Value) End If .Activate Next lngRow End With Application.ScreenUpdating = True End Sub 'Test if Sheets already exist Function Exist_Sheet(strWsh As String) As Boolean On Error Resume Next Exist_Sheet = (Sheets(strWsh).Name = strWsh) End Function
If all is well for you, we will continue with the second part : copy row cells to the new sheet