+ Reply to Thread
Results 1 to 7 of 7

Consolidating data

  1. #1
    Forum Contributor
    Join Date
    07-23-2012
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    211

    Consolidating data

    Hi

    I am using vba to list construction site information. This has created a list of items in a sheet called Site Survey.

    This sheet has resulted in the following data:

    Fence Section Type of Fence Type of Post Length No of Panels No of H Posts No of Corners
    1 Wood Post and Panel Start WITH Post 15.6 9 9
    1 Wood Post and Panel Corner - SINGLE Post 7.8 5 4 1
    1 Wood Post and Panel Corner - SINGLE Post 7.4 4 3 1
    2 Concrete Post and Panel Intermediate - SINGLE Post 6.7 4 5
    2 Concrete Post and Panel Corner - DOUBLE Post 5.3 3 4 1
    3 Post & Rail End WITH Post 6.2 6 7
    3 Post & Rail Start WITH Post 15.6 9 10

    I now want to consolidate this information into a sheet called "Site Data" which shows the total length of each Fence Section, adds the No of Panels, No of H Posts and No of Corners for each Fence Section. So the resulting information in the sheet "Site Data" should look like this:

    Fence Section Type of Fence Total Length Total No of Panels Total No of H Posts Total No of Corners
    1 Wood Post and Panel 30.8 18 16 2
    2 Concrete Post and Panel 12.0 7 9 1
    3 Post & Rail 21.8 15 17 0

    Can anyone advise how I can do this using vba?

    Thanks

    ---------- Post added at 03:31 PM ---------- Previous post was at 03:29 PM ----------

    Gosh, the formatting has messed up in this! I don't know how to tab the data!!!

  2. #2
    Forum Expert mike7952's Avatar
    Join Date
    12-17-2011
    Location
    Florida
    MS-Off Ver
    Excel 2007, Excel 2016
    Posts
    3,520

    Re: Consolidating data

    Try attaching a workbook. With before and after results

    To attach a file, push the button with the paperclip (or scroll down to the Manage Attachments button), browse to the required file, and then push the Upload button.
    Thanks,
    Mike

    If you are satisfied with the solution(s) provided, please mark your thread as Solved.
    Select Thread Tools-> Mark thread as Solved.

  3. #3
    Forum Contributor
    Join Date
    07-23-2012
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    211

    Re: Consolidating data

    Thanks for the advice, Mike.

    I attach the sample workbook
    Attached Files Attached Files

  4. #4
    Forum Expert mike7952's Avatar
    Join Date
    12-17-2011
    Location
    Florida
    MS-Off Ver
    Excel 2007, Excel 2016
    Posts
    3,520

    Re: Consolidating data

    give this a try

    Please Login or Register  to view this content.
    Last edited by mike7952; 08-24-2012 at 11:58 AM.

  5. #5
    Forum Contributor
    Join Date
    07-23-2012
    Location
    London, England
    MS-Off Ver
    Excel 2007
    Posts
    211

    Re: Consolidating data

    WOW!!! Worked perfectly Mike. I spent ages to search forums to get my answer...and you have provided it.

    Thank you

    ps This is now solved but I am not sure how I log it as solved

  6. #6
    Registered User
    Join Date
    08-24-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Consolidating data

    I know this has been solved, but I was wondering what part of this would need to be edited if you wanted to add a few more columns of data that was also duplicate information to the row? For example, I have a name, number and two dates associated with the name that I need to keep together, but they are listed multiple times because they are associated with a different $ amount each time. This macro works great with my spreadsheet for the first two columns, but I cannot figure out how to make it go further to include the next two. Thank you!

  7. #7
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Consolidating data

    Hello NRSmith82, and welcome to the forum.

    Unfortunately you have inadvertently broken one of the forum rules. Please read the following and make the necessary change. Thanks.

    Your post does not comply with Rule 2 of our Forum RULES. Don't post a question in the thread of another member -- start your own thread. If you feel it's particularly relevant, provide a link to the other thread. It makes sense to have a new thread for your question because a thread with numerous replies can be off putting & difficult to pick out relevant replies.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1