I’m hoping someone can help me using xml in my FMX2004 project
Create an animated timeline showing years that allows compairison of when childrens books were written. (about 50+ books)
There will be icons (Flags of the country where the book was written) on the stage.
When a user onRollover there will be a little tooltip that lists the title of the book.
OnRelease on an icon a long description of the book will appear in a scrollArea that will already be predefined on the stage as well.
I know how to do alot of this but my problem come when trying to use XML as a data source for the books long descriptions.
I have learned alot here…how to import XML…how to move from node to node sequentially…etc…
But I have no idea how to get the nodes into an array that I can access non-linerly or am I really sure how to display them that way in my scrollArea.
Here is a portion of the XML I was planning to use.
<books> <character name="Little Red Riding Hood"> <description><![CDATA[<b>Histoires ou contes du temps passé</b><br\><i>Charles Perrault</i><br\>Besides bringing this attractive little girl to literary life, Perrault also (re)told the tales of Cinderella, Sleeping Beauty, Bluebeard, and Puss in Boots. His work, which was not aimed specifically at children, was first published in English in 1729 as Histories, or Tales of Past Times. Told by Mother Goose.]]></description> </character> <character name="Beauty"> <description><![CDATA[<b>La Belle et la Bête</b><br\><i>Madame de Beaumont</i><br\>Jeanne-Marie Leprince de Beaumont was one of the first French writers to recast literary fairy tales specifically for children. Her version of "Beauty and the Beast" is based on a much longer tale written by Mademoiselle de Villeneuve in 1740.]]></description> </character> </books>
I’m figuring this will be the format I will use for all 50 books.
I do know how to load the XML file…but again…
I don’t know how to build the right type of array (can I use the name attribute somehow)
Or write the action script for a button to grab the right node and display it into the scrollArea.
I could sure use any help you might be willing to offer!