I too am considering the automagic generation of a swf using flex/air. I am toying with the idea of using PHP on the server side (http://us3.php.net/manual/en/book.swf.php) to generate the swf and allow the user to download it. I am pretty sure this is something that FLEX can not do on it's own, but would make the best interface for the underlying architecture - passing the vars to another language to actually do the creation.
I do however agree that with the use of a generated XML file - the compiled SWF could have various states (scenes?) and display the correct scene with the user's preferences from the XML. this would make the whole process easier in that I could create one SWF, and don't have to compile on the fly... would love to see what you come up with. -Nathan

