| View previous topic :: View next topic |
| Author |
Message |
alans Newbie

Joined: 29 Apr 2006 Posts: 1
|
Posted: Sat Apr 29, 2006 9:59 pm Post subject: Saving Leading Zeros as text |
|
|
I need to save my spread sheet as a text file with | as the seperator. I always loose the leading zeros in a column of numbers or I get my column of numbers including leading zeros with " around the entry, I can't use the file with the " around the field.
Thanks for your help |
|
| Back to top |
|
 |
carl Super User


Joined: 21 Apr 2003 Posts: 920 Location: Germany
|
Posted: Sun Apr 30, 2006 4:28 am Post subject: |
|
|
you want numbers to appear with leading 0, perhaps thay are telephone numbers. To do this you need a ' at the front, then its read as text and will be saved like that, leave field delimiter as ' and text delimiter as " (ie the default).
when the csv is opened leave text delimiter as " (ie the default)' , but set the column type heading as text. you should see exactly what you had in the spreadsheet. _________________ carl
Using OpenOffice.org 2 on XP sp2 |
|
| Back to top |
|
 |
Dale Super User

Joined: 21 Feb 2005 Posts: 1440 Location: Australia
|
Posted: Sun Apr 30, 2006 3:01 pm Post subject: Re: Saving Leading Zeros as text |
|
|
| alans wrote: | I need to save my spread sheet as a text file with | as the seperator. I always loose the leading zeros in a column of numbers or I get my column of numbers including leading zeros with " around the entry, I can't use the file with the " around the field.
Thanks for your help | I'm pretty sure that the only way to export leading zeros is as Carl wrote: make the field text and export that.
To get rid of the text delimiters, when you save as csv check the Edit Filter Settings box. This will allow you to choose your own text delimiters - even no delimter if you wish. This will save the leading zeros (open in a text editor to check).
If you choose no delimiter, most spreadsheets will import the field as a number and helpfully suppress the leading zeros for you.... _________________ Dale
To err is human, but to destroy your slippers in the process takes a real son of a bitch: Me!
OOo documentation from the source
http://documentation.openoffice.org
Guides, FAQ, How Tos |
|
| Back to top |
|
 |
|