In this post I am going to show how to create a new sheet for each airplane using vba. The macro copies airplane and model values into each new sheet.
Sub Splitdatatosheets() ' Splitdatatosheets Macro Dim rng As Range Dim rng1 As Range Dim vrb As Boolean Dim sht As Worksheet Set rng = Sheets("Sheet1").Range("A4") Set rng1 = Sheets("Sheet1").Range("A4:D4") vrb = False Do While rng <> "" For Each sht In Worksheets If sht.Name = Left(rng.Value, 31) Then sht.Select Range("A2").Select Do While Selection <> "" ActiveCell.Offset(1, 0).Activate Loop rng1.Copy ActiveCell ActiveCell.Offset(1, 0).Activate Set rng1 = rng1.Offset(1, 0) Set rng = rng.Offset(1, 0) vrb = True End If Next sht If vrb = False Then Sheets.Add After:=Sheets(Sheets.Count) ActiveSheet.Name = Left(rng.Value, 31) Sheets("Sheet1").Range("A3:B3").Copy ActiveSheet.Range("A1") Range("A2").Select Do While Selection <> "" ActiveCell.Offset(1, 0).Activate Loop rng1.Copy ActiveCell Set rng1 = rng1.Offset(1, 0) Set rng = rng.Offset(1, 0) End If vrb = False Loop End Sub
Download excel tutorial file
Remember to enable macros and backup your excel file because you can´t undo macros.
(Excel 97-2003 Workbook *.xls)
Split Data Across Multiple Sheets Add-In
Split data across multiple sheets addin let´s you split/categorize data from a sheet across multiple new sheets. The addin is made for Excel 2007/2010/2013.
- Select any single range
- Select specific columns
- Arrange output columns in any order
- Categorize data across sheets in current workbook, new workbook or any open workbook
- Add column headers to each new sheet
What you get
- Split data across multiple sheets addin for Excel *.xlam file.
- Instructions on how to install.
- Instructions on how to use.
- Excel *.xlsx example file.
- 2 licenses, home and office computer.
Is there a money back guarantee?
Sure, you have un-conditional money back guarantee for 14 days.
What about working with merged cells?
The addin won´t work with merged cells. Unmerge cells before usage.
I have more questions?
Use this contact form to let me know.