excel dos txt save

T

TIM

I need to save a sheet in dos .txt format but when I save
it excel put " quotes" on each side of the first colum.
Does anyone no how to get rid of the " "
thanks
 
T

Trevor

Excel will automatically place the values in " when it is non-numeric data
AND if the value of the field includes either a , or ". Commas are the
indication of the division between a cell, so if a cell's data contains a ,
then " must be added to make sure everything goes in one cell. Therefore, "
inside a cell must be replaced with two quotes.

So, what I always do in this situation is to create a separate column which
contains the following formula:
="~"&A1&"~"
This creates a colunm with your values with a ~ on either side. Then copy
the resulting column, shoose Paste->Special->Values on top of the original
column, and delete your temporary column. Now save the file, open it in a
text editor and replace all occurances of "~ and ~" with blanks, then
replace all "" with " and you'll ahve the file you want.

By the way, if you use this file to load data into a database, you'll need
to leave those extra quotes in there. the database interprets the data the
same way excel does, so it knows what those quotes are for.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top