PDA

View Full Version : Import Txt and Parse



bmadaiwty
06-27-2008, 01:37 PM
Hello,

I have a text file (attached) which I need to import to Excel.
After importing - I need to exract the figures from the file, and then link them to a template which I use for various calculations.
The txt file is always the same.

Last year (Aug 2007), RonMcK published a solution for a simmilar challenge
I tried it but it does not seem to the the job. I meen the macro is doing something but the output file is empty...

Any idea how to make this happen?
Without such a solution, I will be forced to punch in a data mannually into the template (and this is something I need to do every week ):(

Any help will be highly appreciated

bmadaiwty
06-27-2008, 01:40 PM
Hope this works now

Ago
06-27-2008, 11:07 PM
it doesnt seem very hard to do, if you could use the textfile that you attached and "manually" make a xls file as a template of how you want the figures.

as i see it you only need to split the data on each row with a space as a delimiter.
of course there is some tests that has to be done if the header is more than one word or not.

upload a "finnished" result and we can take it from there.

bmadaiwty
06-28-2008, 12:36 AM
Thanks Ago, but for me it is not so simple (unfortunatly).
I have tried importing to Excel but since the file is not dlimeted - I need a lot of manual work "fixing" split data. this is why I wanted a macro that takes out the numbers only or simply goes through every line and parses the words into cells (a word/number per cell).