Message Boards Message Boards

Fixed: Export[file,data,"XML"] quotes all string data

Posted 10 years ago

File is derived from Import[file,"XML"]

The standard is double quote ("). Downstream programs reject the file. Is there an option that will change this behavior?

All input strings have double quotes, all output strings have single quotes.

Odd that even the on-screen display (copied to text) shows double quotes, e.g. XMLElement["Id", {}, {"2014-07-25T02:22:57.000Z"}

(Mathematica 10)

FOUND THE DOCUMENTATION under XML/tutorial/ExportingXML
The option is literally quoted. And there's a backslash you don't see.

Export[outfile, newxml, "XML" , "AttributeQuoting" -> "\""];

POSTED BY: Douglas Kubler
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract