Loading ...
Sorry, an error occurred while loading the content.

Re: [FlashLite] "Unable to Load Data" on loadMovie.. FL2 Player bug?

Expand Messages
  • JesterXL
    Dude, what a pain in the ass... happens with empty movieclips too. Bleh! Anyway, here s some sample code; state is neat~! (not)
    Message 1 of 9 , Apr 30 6:31 PM
    View Source
    • 0 Attachment
      Dude, what a pain in the ass... happens with empty movieclips too.  Bleh!  Anyway, here's some sample code; state is neat~!  (not)
       
       
      ----- Original Message -----
      From: JesterXL
      Sent: Sunday, April 30, 2006 9:01 PM
      Subject: Re: [FlashLite] "Unable to Load Data" on loadMovie.. FL2 Player bug?

      I can duplicate your error with the SWF on my Nokia 6680.
       
      I think the problem is because a load operation cannot be cancelled on a phone.  You can't on a PC/Mac either, but usually if you load something, and kill the clip it's linked to, the operation fails silently (on mac it keeps downloading, then fails).
       
      It seems on the phone this thread is somehow locked, and thus, if you remove the target, it gets pissed...
       
      I tried modifying your FLA to remove listeners, delete references, etc., all to no avail.  My suggestion is to do what I suggested months ago, but never did myself, and that is to create a Loader class for Flash Lite 2 content.  Basically, you'll have to accept the fact that once a load is started, there is nothing you can do to stop it.  You can, however, stop the process.  In this case, rather than have deleteAllMc's be disregardful of everyone else, instead, only actually do it if a load has completed.  Once it has, you have no open threads, and thus can delete all mc's.  Basically, you're MovieClipLoader would check in the onLoadInit if it needs to stop, otherwise, keep going.  This Loader class would abstract these Flash Lite oddities.
       
      Hope that helps, and good luck!
       
       
      ----- Original Message -----
      Sent: Sunday, April 30, 2006 8:35 PM
      Subject: [FlashLite] "Unable to Load Data" on loadMovie.. FL2 Player bug?

      I'm developing a FlashLite 2.0 app that does a lot of dynamic image loading and I've run into a problem when running it on the phone. The error doesn't happen when testing on the emulator, is not documented anywhere (that i can find), can't be handled with actionscript, and is driving me crazy.  

      I'm able to repeat the error, and I've created a little sample app to
      show it in action.  
      The SWF: http://www.custom-logic.com/fl2/unable_to_load_data_example.swf 
      The FLA: http://www.custom-logic.com/fl2/unable_to_load_data_example.fla 

      This is how I cause the error:
      1. Create a bunch of MovieClips
      2. Use MovieClipLoader to load jpg's from the web, one at a time
      3. While the MovieClipLoader is still loading an image, Remove all the MovieClips
      4. The FlashLite Player pops up! an "Unable To Load Data" error with choices to "Continue" or "Abort"

      Has anyone else experienced this?  If you run the sample swf on your phone, does it happen to you?  If not, what type of phone do you have?

      I've had problems with this mysterious "Unable to Load Data" error before, and I'm starting to wonder if the problem is specific to my phone/firmware.  I've tried it on two 7610's (both with dodgy chinese firmware v4), and both get the error.

      Thanks,
      Jeff
    • Weyert de Boer
      Flash Player 9 mate? You know more then me, share the secrets I would say. :)
      Message 2 of 9 , May 1, 2006
      View Source
      • 0 Attachment
        Flash Player 9 mate? You know more then me, share the secrets I would say. :)
      • custom.logic
        Thanks for looking into the error. Sorry to pass on the agony and frustration of it, but I m glad to hear that I m the only one it happens to. Do you think
        Message 3 of 9 , May 1, 2006
        View Source
        • 0 Attachment
          Thanks for looking into the error. Sorry to pass on the agony and
          frustration of it, but I'm glad to hear that I'm the only one it
          happens to.

          Do you think this "Unable to Load Data" is just a generic Flash Player
          exception error? Like you said, I'm used to Flash failing silently or
          throwing "onError" events, but this is ugly, abrupt, uniformative, and
          un-catchable (Beta issue? Fingers crossed..). And it's not just the
          MovieClipLoader that can cause it.. I've had it happen with
          MovieClip.loadMovie, LoadVars and XML.load (though not as repeatable).

          Thanks for the code ideas. I actually ran into the problem i posted
          while writing a Loader class to get around the 5 loadMovies per frame
          limitation.. at the moment I'm creating and managing the MovieClips in
          a different set of classes, but your combined solution looks like a
          better way to go.


          --- In FlashLite@yahoogroups.com, "JesterXL" <jesterxl@...> wrote:
          >
          > Dude, what a pain in the ass... happens with empty movieclips too.
          Bleh! Anyway, here's some sample code; state is neat~! (not)
          >
          >
          http://www.jessewarden.com/archives/2006/04/moviecliploader_flash_lite_2.html
          >
          > ----- Original Message -----
          > From: JesterXL
          > To: FlashLite@yahoogroups.com
          > Sent: Sunday, April 30, 2006 9:01 PM
          > Subject: Re: [FlashLite] "Unable to Load Data" on loadMovie.. FL2
          Player bug?
          >
          >
          > I can duplicate your error with the SWF on my Nokia 6680.
          >
          > I think the problem is because a load operation cannot be cancelled
          on a phone. You can't on a PC/Mac either, but usually if you load
          something, and kill the clip it's linked to, the operation fails
          silently (on mac it keeps downloading, then fails).
          >
          > It seems on the phone this thread is somehow locked, and thus, if
          you remove the target, it gets pissed...
          >
          > I tried modifying your FLA to remove listeners, delete references,
          etc., all to no avail. My suggestion is to do what I suggested months
          ago, but never did myself, and that is to create a Loader class for
          Flash Lite 2 content. Basically, you'll have to accept the fact that
          once a load is started, there is nothing you can do to stop it. You
          can, however, stop the process. In this case, rather than have
          deleteAllMc's be disregardful of everyone else, instead, only actually
          do it if a load has completed. Once it has, you have no open threads,
          and thus can delete all mc's. Basically, you're MovieClipLoader would
          check in the onLoadInit if it needs to stop, otherwise, keep going.
          This Loader class would abstract these Flash Lite oddities.
          >
          > Hope that helps, and good luck!
          >
          >
          > ----- Original Message -----
          > From: custom.logic
          > To: FlashLite@yahoogroups.com
          > Sent: Sunday, April 30, 2006 8:35 PM
          > Subject: [FlashLite] "Unable to Load Data" on loadMovie.. FL2 Player
          bug?
          >
          >
          > I'm developing a FlashLite 2.0 app that does a lot of dynamic image
          loading and I've run into a problem when running it on the phone. The
          error doesn't happen when testing on the emulator, is not documented
          anywhere (that i can find), can't be handled with actionscript, and is
          driving me crazy.
          >
          > I'm able to repeat the error, and I've created a little sample app to
          > show it in action.
          > The SWF:
          http://www.custom-logic.com/fl2/unable_to_load_data_example.swf
          > The FLA:
          http://www.custom-logic.com/fl2/unable_to_load_data_example.fla
          >
          > This is how I cause the error:
          > 1. Create a bunch of MovieClips
          > 2. Use MovieClipLoader to load jpg's from the web, one at a time
          > 3. While the MovieClipLoader is still loading an image, Remove all
          the MovieClips
          > 4. The FlashLite Player pops up! an "Unable To Load Data" error with
          choices to "Continue" or "Abort"
          >
          > Has anyone else experienced this? If you run the sample swf on your
          phone, does it happen to you? If not, what type of phone do you have?
          >
          > I've had problems with this mysterious "Unable to Load Data" error
          before, and I'm starting to wonder if the problem is specific to my
          phone/firmware. I've tried it on two 7610's (both with dodgy chinese
          firmware v4), and both get the error.
          >
          > Thanks,
          > Jeff
          >
          > SPONSORED LINKS Programming languages Computer security C
          programming language
          > Computer programming languages Computer training Macromedia
          flash
          >
          >
          >
          --------------------------------------------------------------------------------
          > YAHOO! GROUPS LINKS
          >
          > a.. Visit your group "FlashLite" on the web.
          >
          > b.. To unsubscribe from this group, send an email to:
          > FlashLite-unsubscribe@yahoogroups.com
          >
          > c.. Your use of Yahoo! Groups is subject to the Yahoo! Terms of
          Service.
          >
          >
          >
          --------------------------------------------------------------------------------
          >
        • JesterXL
          That s disturbing to hear you can get it to happen with LoadVars & XML... how? I can understand with MovieClips; you remove it from the displaylist, and thus
          Message 4 of 9 , May 1, 2006
          View Source
          • 0 Attachment
            That's disturbing to hear you can get it to happen with LoadVars & XML...
            how? I can understand with MovieClips; you remove it from the displaylist,
            and thus there is no target... but LoadVars & XML have the activation object
            to keep them alive; how were you getting the error for them?

            Yes, I think it's a generic Flash Player exception, but one that apparenty
            is more challenging to graciously quiet in Flash Lite 2.

            The good news about the MovieClip one is that it is repeateable, consistent,
            and there are solutions to get around it. Bottom line, if we as Flash
            Developers can accept that fact that removeMovieClip is no longer
            syncronous, we'll be fine.

            ----- Original Message -----
            From: "custom.logic" <jeff-groups@...>
            To: <FlashLite@yahoogroups.com>
            Sent: Monday, May 01, 2006 5:54 PM
            Subject: [FlashLite] Re: "Unable to Load Data" on loadMovie.. FL2 Player
            bug?


            Thanks for looking into the error. Sorry to pass on the agony and
            frustration of it, but I'm glad to hear that I'm the only one it
            happens to.

            Do you think this "Unable to Load Data" is just a generic Flash Player
            exception error? Like you said, I'm used to Flash failing silently or
            throwing "onError" events, but this is ugly, abrupt, uniformative, and
            un-catchable (Beta issue? Fingers crossed..). And it's not just the
            MovieClipLoader that can cause it.. I've had it happen with
            MovieClip.loadMovie, LoadVars and XML.load (though not as repeatable).

            Thanks for the code ideas. I actually ran into the problem i posted
            while writing a Loader class to get around the 5 loadMovies per frame
            limitation.. at the moment I'm creating and managing the MovieClips in
            a different set of classes, but your combined solution looks like a
            better way to go.


            --- In FlashLite@yahoogroups.com, "JesterXL" <jesterxl@...> wrote:
            >
            > Dude, what a pain in the ass... happens with empty movieclips too.
            Bleh! Anyway, here's some sample code; state is neat~! (not)
            >
            >
            http://www.jessewarden.com/archives/2006/04/moviecliploader_flash_lite_2.html
            >
            > ----- Original Message -----
            > From: JesterXL
            > To: FlashLite@yahoogroups.com
            > Sent: Sunday, April 30, 2006 9:01 PM
            > Subject: Re: [FlashLite] "Unable to Load Data" on loadMovie.. FL2
            Player bug?
            >
            >
            > I can duplicate your error with the SWF on my Nokia 6680.
            >
            > I think the problem is because a load operation cannot be cancelled
            on a phone. You can't on a PC/Mac either, but usually if you load
            something, and kill the clip it's linked to, the operation fails
            silently (on mac it keeps downloading, then fails).
            >
            > It seems on the phone this thread is somehow locked, and thus, if
            you remove the target, it gets pissed...
            >
            > I tried modifying your FLA to remove listeners, delete references,
            etc., all to no avail. My suggestion is to do what I suggested months
            ago, but never did myself, and that is to create a Loader class for
            Flash Lite 2 content. Basically, you'll have to accept the fact that
            once a load is started, there is nothing you can do to stop it. You
            can, however, stop the process. In this case, rather than have
            deleteAllMc's be disregardful of everyone else, instead, only actually
            do it if a load has completed. Once it has, you have no open threads,
            and thus can delete all mc's. Basically, you're MovieClipLoader would
            check in the onLoadInit if it needs to stop, otherwise, keep going.
            This Loader class would abstract these Flash Lite oddities.
            >
            > Hope that helps, and good luck!
            >
            >
            > ----- Original Message -----
            > From: custom.logic
            > To: FlashLite@yahoogroups.com
            > Sent: Sunday, April 30, 2006 8:35 PM
            > Subject: [FlashLite] "Unable to Load Data" on loadMovie.. FL2 Player
            bug?
            >
            >
            > I'm developing a FlashLite 2.0 app that does a lot of dynamic image
            loading and I've run into a problem when running it on the phone. The
            error doesn't happen when testing on the emulator, is not documented
            anywhere (that i can find), can't be handled with actionscript, and is
            driving me crazy.
            >
            > I'm able to repeat the error, and I've created a little sample app to
            > show it in action.
            > The SWF:
            http://www.custom-logic.com/fl2/unable_to_load_data_example.swf
            > The FLA:
            http://www.custom-logic.com/fl2/unable_to_load_data_example.fla
            >
            > This is how I cause the error:
            > 1. Create a bunch of MovieClips
            > 2. Use MovieClipLoader to load jpg's from the web, one at a time
            > 3. While the MovieClipLoader is still loading an image, Remove all
            the MovieClips
            > 4. The FlashLite Player pops up! an "Unable To Load Data" error with
            choices to "Continue" or "Abort"
            >
            > Has anyone else experienced this? If you run the sample swf on your
            phone, does it happen to you? If not, what type of phone do you have?
            >
            > I've had problems with this mysterious "Unable to Load Data" error
            before, and I'm starting to wonder if the problem is specific to my
            phone/firmware. I've tried it on two 7610's (both with dodgy chinese
            firmware v4), and both get the error.
            >
            > Thanks,
            > Jeff
            >
            > SPONSORED LINKS Programming languages Computer security C
            programming language
            > Computer programming languages Computer training Macromedia
            flash
            >
            >
            >
            --------------------------------------------------------------------------------
            > YAHOO! GROUPS LINKS
            >
            > a.. Visit your group "FlashLite" on the web.
            >
            > b.. To unsubscribe from this group, send an email to:
            > FlashLite-unsubscribe@yahoogroups.com
            >
            > c.. Your use of Yahoo! Groups is subject to the Yahoo! Terms of
            Service.
            >
            >
            >
            --------------------------------------------------------------------------------
            >







            Yahoo! Groups Links
          • custom.logic
            Yeah, I agree that the LoadVars one is a bit scary. We still haven t been able to nail it down into a repeatable example like the MovieClip, but I think
            Message 5 of 9 , May 1, 2006
            View Source
            • 0 Attachment
              Yeah, I agree that the LoadVars one is a bit scary. We still haven't
              been able to nail it down into a repeatable example like the
              MovieClip, but I think understanding a bit more about what's happening
              with the MovieClips might give us more to go on.

              Here's one example where we've run into it (at least we think this is
              what's happening):
              1. LoadVars.load request is sent to a php page
              2. php page does some calculations
              3. php hits some bad code that causes a fatal error
              4. Flash hears nothing from the server, up comes the "Unable to Load Data"

              So the obvious solution is to fix the server code so fatal errors
              don't occur, but what about other times when the server might fail to
              respond? It seems like LoadVars should trigger an onLoad(false)
              instead of popping up the Player error.

              Jeff

              --- In FlashLite@yahoogroups.com, "JesterXL" <jesterxl@...> wrote:
              >
              > That's disturbing to hear you can get it to happen with LoadVars &
              XML...
              > how? I can understand with MovieClips; you remove it from the
              displaylist,
              > and thus there is no target... but LoadVars & XML have the
              activation object
              > to keep them alive; how were you getting the error for them?
              >
              > Yes, I think it's a generic Flash Player exception, but one that
              apparenty
              > is more challenging to graciously quiet in Flash Lite 2.
              >
              > The good news about the MovieClip one is that it is repeateable,
              consistent,
              > and there are solutions to get around it. Bottom line, if we as Flash
              > Developers can accept that fact that removeMovieClip is no longer
              > syncronous, we'll be fine.
            • JesterXL
              What does onData return in it s first parameter in those situations? ... From: custom.logic To:
              Message 6 of 9 , May 1, 2006
              View Source
              • 0 Attachment
                What does onData return in it's first parameter in those situations?

                ----- Original Message -----
                From: "custom.logic" <jeff-groups@...>
                To: <FlashLite@yahoogroups.com>
                Sent: Monday, May 01, 2006 7:58 PM
                Subject: [FlashLite] Re: "Unable to Load Data" on loadMovie.. FL2 Player
                bug?


                Yeah, I agree that the LoadVars one is a bit scary. We still haven't
                been able to nail it down into a repeatable example like the
                MovieClip, but I think understanding a bit more about what's happening
                with the MovieClips might give us more to go on.

                Here's one example where we've run into it (at least we think this is
                what's happening):
                1. LoadVars.load request is sent to a php page
                2. php page does some calculations
                3. php hits some bad code that causes a fatal error
                4. Flash hears nothing from the server, up comes the "Unable to Load Data"

                So the obvious solution is to fix the server code so fatal errors
                don't occur, but what about other times when the server might fail to
                respond? It seems like LoadVars should trigger an onLoad(false)
                instead of popping up the Player error.

                Jeff

                --- In FlashLite@yahoogroups.com, "JesterXL" <jesterxl@...> wrote:
                >
                > That's disturbing to hear you can get it to happen with LoadVars &
                XML...
                > how? I can understand with MovieClips; you remove it from the
                displaylist,
                > and thus there is no target... but LoadVars & XML have the
                activation object
                > to keep them alive; how were you getting the error for them?
                >
                > Yes, I think it's a generic Flash Player exception, but one that
                apparenty
                > is more challenging to graciously quiet in Flash Lite 2.
                >
                > The good news about the MovieClip one is that it is repeateable,
                consistent,
                > and there are solutions to get around it. Bottom line, if we as Flash
                > Developers can accept that fact that removeMovieClip is no longer
                > syncronous, we'll be fine.







                Yahoo! Groups Links
              • custom.logic
                Well, I just tried to put together a little test situation to figure out what is going on, but no dice. I made a little test that followed the steps i
                Message 7 of 9 , May 1, 2006
                View Source
                • 0 Attachment
                  Well, I just tried to put together a little test situation to figure
                  out what is going on, but no dice. I made a little test that followed
                  the steps i described, but wasn't able to get the "Unable to Load
                  Data" error to appear. I tried causing various php errors, turning
                  "display_errors" off, and putting in long sleep periods.

                  The FlashLite app where we see the "Unable to Load Data" happening is
                  a multiplayer game using php as a game server. A player chooses a
                  move for the round, they send the move to the server (LoadVars), the
                  server calculates the results, and the results are returned to the
                  players. Player 1 sends in her move and her app polls the server
                  until Player 2 is done his move. During this polling stage, we
                  sometime get the "Unable To Load Data" message popping up. It only
                  happens after a few rounds of play.

                  The php fatal error was our latest hypothesis. Our only other
                  theories are GPRS connection failures or something specific to our
                  phones. It's been impossible to predict or repeat, and it doesn't
                  happend on the emulator which makes debugging difficult.

                  --- In FlashLite@yahoogroups.com, "JesterXL" <jesterxl@...> wrote:
                  >
                  > What does onData return in it's first parameter in those situations?
                  >
                Your message has been successfully submitted and would be delivered to recipients shortly.