Flex 4: Loading XML into a Model Actionsript Class
- by Steve
I'm trying to create an actionscript class to serve as a data model for my Flex app. I already have a formatted XML file to read from, and when I was simply declaring the data service in my MXML app I used this code inside the declarations:
I'm now trying to create a model class and can't seem to get the same functionality. I've tried importing mx.rpc.http.HTTPService but i think this is different. And using the XML class doesn't seem to allow the ability to define a source url.
I'm assuming that I am able to declare a public var inside my class that will read this XML source file as I had done in the main app. If this is possible, how do I do it?