save to XML?

Can I save informations to a XML that can be readed after?

I know how to do to read from XML but I dont know if I can save information to an XML file

if someone can help me, thanks

you can write to the XML file all of the information that you need to read later. Yes, the information can be read.

cheers,

?:)

sooooo.... how can I do that in corona ? :S

i'm not saying to write manually, i'm saying to save information to a xml

it's like... I need that my code read an xml file and after write this xml, saving his informations to "informations.xml"

and keep doing this, saving in "informations.xml"

get it? :S

I know this doesn't answer your question directly, as you may have no choice but to use XML depending on your project's requirements, but in case you can explore alternatives, have you tried looking into JSON?

It has very similar (in many projects, identical) use cases, is very lightweight, and is much easier to use in Corona (due to the included JSON library).

The best part is, you can encode/decode JSON as well, making it easy to save JSON files for later loading.

Here's a tutorial:
http://blog.anscamobile.com/2011/08/tutorial-exploring-json-usage-in-corona/

If you are just to read and write the info locally, you may use SQLite database instead of dealing with xml files and parsing issue.

My initial idea was to see the xml of my database and then display on the screen, but I do not know how to do this I thought it best to download the xml of the Internet and read it

views:1637 update:2011/10/18 15:01:22
corona forums © 2003-2011