Search range and split into different columns based on a cell value

Craig1

Active Member
Joined
Jun 11, 2009
Messages
322
Hi guys,

Help needed again. What I need to do is:-

Using VBA I have one set of data which can change between each down load, it starts in $A$7 to column $E but the row number can differ.
For this example say $A$7 to $D100 is my range and based on the value in column E I want to transfer the data from say A7 to E7 into a new set of columns starting H7.
The value in column E will be Line 1, Line 2 etc so I want the code to loop around the range and all Line 1's transfer to a new set of columns starting in H7 then all Line 2's transfer to M7 and so on.

I have tried searching for an answer but my search criteria must be off a little.

i hope I have explained it enough for you guys to understand, all info is in the same worksheet.

Thanks in advance
BUVAA70005</SPAN>06-Feb-13 16:17:08</SPAN>07-Feb-13 05:50:01</SPAN>Line 1</SPAN>
BEAMA00024</SPAN>06-Feb-13 22:39:17</SPAN>07-Feb-13 01:14:01</SPAN>Line 1</SPAN>
BEG80078</SPAN>06-Feb-13 22:57:43</SPAN>07-Feb-13 00:06:26</SPAN>Line 7</SPAN>
BEAAA30048</SPAN>06-Feb-13 23:15:15</SPAN>07-Feb-13 00:21:10</SPAN>Line 5</SPAN>
CQZBA50006</SPAN>06-Feb-13 23:36:06</SPAN>07-Feb-13 00:44:20</SPAN>Line 1</SPAN>
BEG80079</SPAN>07-Feb-13 00:06:26</SPAN>07-Feb-13 01:05:34</SPAN>Line 5</SPAN>
BEAAA30049</SPAN>07-Feb-13 00:21:10</SPAN>07-Feb-13 01:17:34</SPAN>Line 5</SPAN>
CQZBA50007</SPAN>07-Feb-13 00:44:20</SPAN>07-Feb-13 01:32:43</SPAN>Line 5</SPAN>
BEG80080</SPAN>07-Feb-13 01:05:34</SPAN>07-Feb-13 02:13:54</SPAN>Line 1

<TBODY>
</TBODY><COLGROUP><COL><COL span=2><COL></COLGROUP>
 
Thanks for that Ant, I had to do a few minor changes and it's now working great.

Thanks for all the help.

Craig.
 
Upvote 0

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"

Forum statistics

Threads
1,214,606
Messages
6,120,497
Members
448,967
Latest member
visheshkotha

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top