macro required to format csv file with pipes into excel

mingandmong

Active Member
Joined
Oct 15, 2014
Messages
339
Hi

I have to import a .csv file into excel and prepare the worksheet before i can use it, can a macro be written

currentley i hace to

a) paste .csv into excel
b) select column A
c)txt wizard comes up select delimited, then next
d)populate other tab and put in pipe | then next
e)then select txt for 2 of the columns instead of general (column F & G) before finnish

Code:
[B]today[/B]  with pipe ( data should be coulmn a, b,c,d,e,f,g,h,i,j,k, but got muddled and placed all in A

[TABLE]
 <colgroup><col style="font-weight:bold; width:30px;  "><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"></colgroup><tbody>[TR="bgcolor: #cacaca"]
[TD]*[/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]1[/TD]
[TD]7264164|ACPcted_|COM||||||2014-11-28 05:18:10|2014-11-28 14:15:43||[/TD]
[TD]*[/TD]
[TD]*[/TD]
[TD]*[/TD]
[TD]*[/TD]
[TD]*[/TD]
[TD]*[/TD]
[TD]*[/TD]
[/TR]
</tbody>[/TABLE]
 
[URL="http://www.excel-jeanie-html.de/index.php?f=1"]Excel tables to the web - Excel Jeanie Html 4[/URL]
]



[CODEtoday after completing wizard

*ABCDEFGHIJK
HargreavCOMPM61N026022C710
HargreavCOMLD21H743022P010

<colgroup><col style="font-weight:bold; width:30px; "><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"></colgroup><tbody>
[TD="bgcolor: #cacaca, align: center"]22[/TD]
[TD="align: right"]8324960[/TD]

[TD="align: right"]1[/TD]
[TD="align: right"]1325739[/TD]

[TD="align: right"]########[/TD]
[TD="align: right"]########[/TD]
[TD="align: right"]00:05:12[/TD]

[TD="bgcolor: #cacaca, align: center"]23[/TD]
[TD="align: right"]8324960[/TD]

[TD="align: right"]2[/TD]
[TD="align: right"]4865360[/TD]

[TD="align: right"]########[/TD]
[TD="align: right"]########[/TD]
[TD="align: right"]00:02:49[/TD]

</tbody>

Excel tables to the web - Excel Jeanie Html 4

][/CODE]
 

Excel Facts

Control Word Wrap
Press Alt+Enter to move to a new row in a cell. Lets you control where the words wrap.
Hi Andrew, being a total newbie i do not think the record a new macro can work whilst the the wizard is active, i bow to your knowlege due to helping me in the past ?
 
Upvote 0

Forum statistics

Threads
1,223,268
Messages
6,171,100
Members
452,379
Latest member
IainTru

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