Data arrangement macro

makinmomb

Active Member
Joined
Dec 23, 2013
Messages
401
I want to re arrange my data as follows , if i do manually it will take long
, cell reference A meaning on sheet 2

[TABLE="width: 192"]
<colgroup><col width="64" span="3" style="width:48pt"> </colgroup><tbody>[TR]
[TD="class: xl65, width: 64"]D3[/TD]
[TD="class: xl63, width: 64"]TO[/TD]
[TD="class: xl63, width: 64"]A1[/TD]
[/TR]
[TR]
[TD="class: xl63"]E3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A2[/TD]
[/TR]
[TR]
[TD="class: xl63"]J3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A3[/TD]
[/TR]
[TR]
[TD="class: xl63"]O3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A4[/TD]
[/TR]
[TR]
[TD="class: xl63"]N3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A5[/TD]
[/TR]
[TR]
[TD="class: xl63"]F3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A6[/TD]
[/TR]
[TR]
[TD="class: xl63"]G3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A7[/TD]
[/TR]
[TR]
[TD="class: xl63"]I3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A8[/TD]
[/TR]
[TR]
[TD="class: xl63"]H3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A9[/TD]
[/TR]
[TR]
[TD="class: xl63"]B3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A10[/TD]
[/TR]
[TR]
[TD="class: xl63"]K3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A11[/TD]
[/TR]
[TR]
[TD="class: xl63"]M3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A12[/TD]
[/TR]
[TR]
[TD="class: xl66"]C3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A13[/TD]
[/TR]
[TR]
[TD="class: xl64"][/TD]
[TD="class: xl63"][/TD]
[TD="class: xl63"][/TD]
[/TR]
[TR]
[TD="class: xl66"]W3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A14[/TD]
[/TR]
[TR]
[TD="class: xl66"]U3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A15[/TD]
[/TR]
[TR]
[TD="class: xl66"]V3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A16[/TD]
[/TR]
[TR]
[TD="class: xl66"]S3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A17[/TD]
[/TR]
[TR]
[TD="class: xl66"]T3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A18[/TD]
[/TR]
[TR]
[TD="class: xl66"]X3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A19[/TD]
[/TR]
[TR]
[TD="class: xl66"]AA3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A20[/TD]
[/TR]
[TR]
[TD="class: xl63"]Y3[/TD]
[TD="class: xl63"]TO[/TD]
[TD="class: xl63"]A21[/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
The macro will go into a blank file it will be called file3 ( macro file ) then it will go read the path of these files

c:\rickmagic\file1
c:\rickmagic\file2

File 2 will thus change , picking the data from the cells i have quoted to where
I want them
 
Last edited:
Upvote 0
The macro will go into a blank file , then it will go read the path of these files

c:\rickmagic\file1
c:\rickmagic\file2

File 2 will thus change , picking the data from the cells i have quoted to where
I want them
Are these Excel workbook files or text files?
 
Last edited:
Upvote 0
I have purposely named the folder rickmagic as i know rick you can make this magic happen

Thank you in advance
 
Upvote 0
I need this kind of urgent otherwise the data is huge ,
it is not worth doing this is manually for 100 trucks plus
 
Upvote 0

Forum statistics

Threads
1,224,827
Messages
6,181,197
Members
453,022
Latest member
RobertV1609

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