Solved

VBA Macro to clean up report

Posted on 2016-10-26
4
30 Views
Last Modified: 2016-10-26
I have a huge report in Excel that needs to be put in list format.  The Customer ID and name only appears at the beginning of each section.  Does anyone know how to write a macro or code to copy the ID down through each related line in the section?  Attached is a before and after shot of a slice of the report.

Thanks for your help!
Insert-column-Copy-Down.xlsx
0
Comment
Question by:thutchinson
  • 3
4 Comments
 

Author Comment

by:thutchinson
ID: 41860863
Here's the sample file I forgot to attach.  Sorry:)
0
 
LVL 21

Accepted Solution

by:
Ejgil Hedegaard earned 500 total points
ID: 41861125
You can do it with a couple of formulas, see column E to H.
Then filter for not empty on column G, and copy the filtered result to After sheet.
Insert-column-Copy-Down.xlsx
1
 

Author Comment

by:thutchinson
ID: 41861271
That's awesome! Thank you so very much Ejgil!
0
 

Author Closing Comment

by:thutchinson
ID: 41861452
I am very pleased.  Thank you so much!
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

A little background as to how I came to I design this code: Around 5 years ago I designed an add-in that formatted Excel files to a corporate standard, applying different cell colours and font type depending on whether the cells contained inputs,…
This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
This Micro Tutorial will demonstrate how to use longer labels with horizontal bar charts instead of the vertical column chart.
This Micro Tutorial demonstrates in Microsoft Excel how to consolidate your marketing data by creating an interactive charts using form controls. This creates cool drop-downs for viewers of your chart to choose from.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now