Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Junior Member
 
Posts: 1
Default Excel VBA macro, search - accumulate - delete original

I have a workbook with 5 columns and a number of rows that looks like this:
A B C D E F
1 X 0 0 0
2 V U 2 3 4
3 Y 0 0 0
4 U 5 6 7
5 Z 0 0 0
...

What I am trying to accomplish is a macro (or any other method) to first search the B-column after any value(Isblank?) and when it finds a value in the B column, use this value and search for the same value in the A-column.
Then It should create a new row with the values(text string) from both A-column cells, in this case V + U entered in the C-column and add the values from the D,E,F columns of both the first row where it found the value in the B-column and the second row where it found the value in the A column.
After this is done, both the original rows should be deleted and only this new row should exist.
After this, it should continue and search in the B-column for the next value and repeat this process.

Below is my preferd output:

A B C D E F
1 X 0 0 0
2 Y 0 0 0
3 Z 0 0 0
4 V+U 7 9 11
...


I hope you understand what I am trying to explain :)
Is this possible?
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Subtotal macro and delete original data ExcelNovice Excel Programming 3 January 2nd 08 12:18 AM
macro save as delete original file Pam M Excel Programming 2 September 25th 07 08:24 PM
Delete duplicate and original entries in excel [email protected] Excel Discussion (Misc queries) 3 April 30th 07 06:48 AM
how do you delete sheets in excel but keep your original? Bridgette Excel Discussion (Misc queries) 6 October 20th 05 11:39 PM
Macro to search, compare, copy and delete mark_l_88 Excel Programming 2 April 24th 04 09:08 PM


All times are GMT +1. The time now is 05:50 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"