DAT to XLS

N

nick

Hi,

I have a Dat file which need to be pput in to excel. I know the # of
characters( different for each cell) that need to go in every cell and even
the # of colums the data has to go in to. So instead of doing the fixed
length, which takes a lot of time is there any function or program that i cld
use to convert the data in to excel by providing the conditions like 1st cell
i need 3 charactars from the dat file and the next 4 in 2nd and next 3 in 3
etc
EXAMPLE:
DAT file is in the format
11113333444455556666

I want this to be put in excel in the format:
1st cell with 4char: 1111
2nd cell with 3: 333
3rd with 5: 34444

Etc........please help as this is very urgent. Thanks. I hope i framed the Q
right and understandable
 
J

Jim Rech

So instead of doing the fixed | length,

I don't know what that means but the Text Import Wizard should pop up when
you open the file in Excel. You would choose 'fixed width' and then where
the breaks are.

--
Jim
| Hi,
|
| I have a Dat file which need to be pput in to excel. I know the # of
| characters( different for each cell) that need to go in every cell and
even
| the # of colums the data has to go in to. So instead of doing the fixed
| length, which takes a lot of time is there any function or program that i
cld
| use to convert the data in to excel by providing the conditions like 1st
cell
| i need 3 charactars from the dat file and the next 4 in 2nd and next 3 in
3
| etc
| EXAMPLE:
| DAT file is in the format
| 11113333444455556666
|
| I want this to be put in excel in the format:
| 1st cell with 4char: 1111
| 2nd cell with 3: 333
| 3rd with 5: 34444
|
| Etc........please help as this is very urgent. Thanks. I hope i framed the
Q
| right and understandable
 
N

nick

I am sorry i meant fixed width in the text import wizard. the problem with
this is 1 row is gonna be split in to 130 colums with a fixed character
length in each cell of every column. So i was lookin for an alternative.
Thanks for your help
 
M

MrShorty

So you need to import a text file.
Row 1 needs to be parsed in one way.
Rows 2+ need to be parsed a different way.

I think I would do it like this:
1) Import file, placing column breaks where you want the 1st row
parsed.
2) Delete rows 2+
3) Import file again, placing column breaks where you want rows 2+
parsed and tell it to start import at row 2. Be sure to place the
imported file in the row below where you put the first row.

Will that work?
 
Top