2 Replies Latest reply on Jun 10, 2008 12:15 AM by relic245

    History action script error

    relic245
      I'm new to flex but have a problem thats giving me grief....

      My main app basically has a menu and a mx.moduleLoader on the screen,

      I have then created a series of 'pages' as modules. Then when the user selects a menu, it changes the modules loaders url to point to the pages swf file. All goes well, until i click the third menu item (its always the third, no matter which order i click them in) then i get a java script error and the module doesn't load. The error says:

      error type 1034: Type Coercion fault: Cannot convert mx.managers.HistoryManagerImp@66bac57 to mx.managers.IHistoryManager

      So I guess I need to be doing something with the history manager when i'm loading swf's but what? Thanks
      for any help.

        • 1. Re: History action script error
          matthew horn Level 3
          If you're not using history management, disable it. You can disable history management for an entire application by setting the value of the historyManagementEnabled property to false on the <mx:Application> tag.

          hth,
          matt horn
          flex docs
          • 2. Re: History action script error
            relic245 Level 1
            Thanks for the reply, unfortunately it did not fix the issue.

            I have broken it down to the simplest possible terms and started a new app. The new app has one component, a mx.moduleLoader and 2 buttons, each button calls an actionscript function that loads a module, one.swf and two.swf.

            The 2 modules each contain one button each, and everything works fine.
            If I add an empty viewstack to either one of the modules the error returns. (The viewstack doesn't have to be empty, i'm just trying to find the lowest demominator). The problem only appears in the debug version of the flash player, everything works fine in a normal player.

            Looks to me like I have found a bug here, anyone agree with that and I'll report it...

            I can post my code if anyone wants to see it, i'm new to this forum and am not sure what the etiquette is on posting code.

            Cheers
            tony