4 Replies Latest reply on May 13, 2009 6:43 AM by JeffryHouser

    How do I instantiate an object in FLEX or AIR?



      There must be something that I don't know that makes instantiation of an object different when doing it from <mx:WindowedApplication></mx:WindowedApplication> class and in the normal XXXX.as class.

      For example I couldn't connect to SQLite. I put all the connection code into the function. Then I put this function into the both mentioned places. When putting the same function into the Application class it worked but putting it to the XXXX.as class it didn't work.

      What is it, that I don't know about that prevents executing this function correctly. Code of the function works correctly. Maybe there are some hidden variables, paths etc.

      Yesterday, a similar problem appeared with 3rd party code that I've added to my application. And the same happened, it works in the Application class but doesn't work in XXXX.as class.

      Please help,