Saving to unicode file not preserving quotation marks

G

Grafalgar

Hi all!

I have an excel workbook that consists entirely of text that needs to
be saved to unicode txt files. The txt files gets processed and is
imported into a C++ application that processes the strings.

The problem is that quite a lot of the text includes quotation marks,
for example:

JOHN REPLIED: \\"THERE IS NOTHING I CAN DO ABOUT IT!\\"

Since this is processed in a C++ application we insert the \ before the
quotes.

The problem is when excel saves out to a txt file it drops the quotes
.. so I end up with:

JOHN REPLIED: \THERE IS NOTHING I CAN DO ABOUT IT!\

Which means I have to go in and manually add the quotes.

Is there anything I can do to get around this? I have tried looking
for a setting but to no avail, and my searches online have failed
miserably.

thank you!

Graf
 
J

jaf

Hi Graf,
If your doing a file>save as, ".txt" in Excel you have no choice.

On simple solution is to write a VBA routine to save the file.
Use write # instead of print # to wrap text in quotes.
 

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