Professional Documents
Culture Documents
Combining Multiple Worksheets in To Single Sheet
Combining Multiple Worksheets in To Single Sheet
Dim sh As Worksheet
var = 0
var = 1
Exit For
End If
Next sh
Sheets(2).Activate
Sheets(2).Range(Range("a1"), Range("A1").End(xlToRight)).Copy
Sheets(1).Activate
With sh
End With
End If
Next sh
ActiveWindow.DisplayGridlines = False
Range("A1").CurrentRegion.Select
Selection.Columns.AutoFit
End Sub
Follow the Steps
1. Be sure to enable macros before you start working with the code
2. This code is dynamic and can be used in your own workbook as well
3. The code will create a new sheet as Consolidated Data to consolidate the data.
If you already have that sheet in your workbook, the data will be consolidated
in that sheet
4. The blue and bold marked parts in the code can be changed to fit your data
range
Link:
https://www.goodly.co.in/consolidate-data-from-multiple-sheets/