Solved

Copy Data from one worksheet to another worksheet

Posted on 2014-04-17
4
269 Views
Last Modified: 2014-04-18
Attached is a workbook that needs the SUN to SAT data from the ActiveDays Worksheet copied to the appropriate cells within the ID worksheet.

In the ActiveDays worksheet, there is one row of SUN to SAT data, for each major category, ID_Parent, within the ID worksheet.  In the ID worksheet, there is the ID_Parent column (Col A), with several other minor categories, or children (Col B), of the ID_Parent.

What is needed is a way, probably VBA, to copy the SUN to SAT data into each column, from the ActiveDays worksheet into the same fields of the ID worksheet, based on the Col A (ID_Parent) criteria.  Rows 2 and 3 of the ID worksheet provide an example.

Therefore, if a cell in column A, within the ID worksheet is ABCD, then the code would look for ABCD in the Activedays worksheet, and copy the values from columns B to H into columns D to J of the ID worksheet.
Combine-Tables.xlsx
0
Comment
Question by:Cook09
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 22

Expert Comment

by:Flyster
ID: 40008124
I believe you can achive that result using SUMPRODUCT. In cell D2 the formula would be:

=SUMPRODUCT((ActiveDays!B:B),--(ActiveDays!$A:$A=$A2))

See attached.

Flyster
Combine-Tables.xlsx
0
 

Author Comment

by:Cook09
ID: 40008904
Flyster,

Yes it seems to work, but takes a very long time to update the calculations.  I had to put it to Manual.  Is there another method that is not so processor intensive?  But, I do like the formula aspect.

Cook09
0
 
LVL 22

Accepted Solution

by:
Flyster earned 500 total points
ID: 40009022
Here it is using SUMIF. D2 formula is:

=SUMIF(ActiveDays!$A:$A,$A2,ActiveDays!B:B)
Combine-Tables-Sumif.xlsx
0
 

Author Closing Comment

by:Cook09
ID: 40009461
Exactly what I needed.  Thanks
0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Microsoft Office Picture Manager was included in Office 2003, 2007, and 2010, but not in Office 2013. Users had hopes that it would be in Office 2016/Office 365, but it is not. Fortunately, the same zero-cost technique that works to install it with …
Excel can be a tricky bit of software to get your head around. Whilst you’ll be able to eventually get to grips with the basic understanding of how to get by, there are a few Excel tips that not everybody will even know about let alone know how to d…
This Micro Tutorial demonstrate the bugs in Microsoft Excel for Mac with Pivot Charts.
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…

628 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