DAT file spacing
Newzed
Posts: 2,503
If I type in Excel:
and then copy and paste it into a DAT file, it appears like this:
trav3·· WORD· " L······ ",····· 150
····· ··· WORD· " I······ ",····· 200
How can I get rid of the extra spaces after L and I, and after ",.· I've tried resetting the tab stops but that doesn't help.· It still compiles OK, but just doesn't look neat.
Thanks
Sid
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Yesterday is history, tomorrow is a mystery, and today is a gift.
That is why they call it the present.
Don't have VGA?
Newzed@aol.com
·
and then copy and paste it into a DAT file, it appears like this:
trav3·· WORD· " L······ ",····· 150
····· ··· WORD· " I······ ",····· 200
How can I get rid of the extra spaces after L and I, and after ",.· I've tried resetting the tab stops but that doesn't help.· It still compiles OK, but just doesn't look neat.
Thanks
Sid
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Yesterday is history, tomorrow is a mystery, and today is a gift.
That is why they call it the present.
Don't have VGA?
Newzed@aol.com
·
Comments
Within quotes the tabs separating the EXCEL fields will become spaces. However it seems the IDE does not honour the settings when reading from the clipboard....
As you most likely want to keep some separators, you should edit it before pasting into the IDE in any program editor
When I copied and pasted from Excel, the DAT list displayed:
trav3·· WORD· " L······ ",····· 150
····· ··· WORD· " I······ ",····· 200
I highlighted the portion shown in red, clicked on Edit/Find Replace and typed:
REPLACE· WORD· "L",
clicked on Replace All
and the DAT list displayed:
WORD· "L",····· 100
I repeated the process for I, R and O, which are my four travel directions and in a matter of minutes everything was OK.· The extra spaces before the number are of no importance - the program just sees the number.
Letting Excel format my DAT list from just two entries - direction and coordinate - ·will cut the DAT list formatting time in half.
As my Uncle Ed used to say, "There's more than one way to·make a mule get up and go".
Sid
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Yesterday is history, tomorrow is a mystery, and today is a gift.
That is why they call it the present.
Don't have VGA?
Newzed@aol.com
·