Skip navigation
benefit-ms
Currently Being Moderated

Error loadin external files in FL3.1 in s60

Feb 25, 2009 10:24 PM

Hi

I used mobile packager for s60 and FL3.1 has a cery good performance
but unfortunately my swf file couldn't load other movies located in storage card/others folder
I used this command
loadMovieNum("file:///e:/others/myapp.swf", this);

also tried loadMovieNum("file://e:/others/myapp.swf", this);
but nothing worked

I don't want to put the other movies in the same folder of the launcher app.

please help
  • Currently Being Moderated
    Community Member
    Feb 26, 2009 4:11 PM
    This is the correct path style:

    loadMovieNum("file://e:/others/myapp.swf", this);

    and make sure that the folder is visible in the device file manager.

    Mark
    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Mar 3, 2009 2:58 AM
    Can you post your fla and swf please?

    Mark
    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Mar 5, 2009 3:49 AM
    Hi benefit-ms,

    This is expected behaviour, we changed the security model in the FL3.1 Distributable Player to make it easier for you to build applications that use multiple local files and the Internet.

    For SWF files that load other SWF files or XML, video etc from the local file system, they must do this from the root folder (or below) specified in the Mobile Packager. This is called an application sandbox, which means that if you want to load other SWF files then they must be in the same folder or in a sub-folder below.

    The user of the device must specify where they wish applications to be installed, dependant on space available. It isn't possible to split applications across multiple drives without making the process of creating packages extremely complex. Further, alot considerable number of users do not have memory cards and this would cause your application install to fail.

    Regards,

    Mark
    www.flashmobileblog.com
    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Mar 21, 2009 3:45 PM
    I am having trouble loading images from external sources.
    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Mar 22, 2009 3:52 AM
    Care to give us some information bobbyworld?
    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Mar 22, 2009 8:48 PM
    In the external XML I am loading there is a URL to an image located at
    http://l.yimg.com/a/i/us/we/52/33.gif

    When running from my device, I get an error loading image.

    System.security.loadPolicyFile(" http://weather.yahooapis.com/crossdomain.xml");

    fscommand2("FullScreen", true);
    var weatherData:XML = new XML();
    var scopeReference = this;
    weatherData.ignoreWhite = true;


    // Using wrong XML file name for testing.
    weatherData.load(" http://weather.yahooapis.com/forecastrss?p=32821");
    weatherData.onLoad = handleDataLoad;

    function handleDataLoad(success:Boolean):Void {
    if (success)
    {
    buildWeatherReport(this);
    trace (this.firstChild.childNodes[0].childNodes[12].childNodes[6].firstChil d.nodeValue);
    trace(this.firstChild.childNodes[0].childNodes[12].childNodes[5].attr ibutes.temp);
    } else {
    trace("No XML Data Loaded");
    }
    }

    function buildWeatherReport(weatherData:XML):Void {
    //txtDateDisplay.text =
    weatherData.firstChild.childNodes[0].childNodes[12].childNodes[5].att ributes.temp + " degrees";

    /* this.createEmptyMovieClip("weather_mc",10);
    weather_mc._x = 0;
    weather_mc.y = 0;
    weather_mc.loadMovie(weatherData.firstChild.childNodes[0].childNodes[ 11].childNodes[4].firstChild);*/
    //image_mc.loadMovie(weatherData.firstChild.childNodes[0].childNodes[ 11].childNodes[4].firstChild);

    weather_txt.html = true;
    //weather_txt.htmlText = "<b> this is bold text</b>";
    weather_txt.htmlText = weatherData.firstChild.childNodes[0].childNodes[12].childNodes[6].fir stChild.nodeValue;
    }
    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Mar 23, 2009 3:38 AM
    Hi Bobby,

    Your code works just fine on my phone, and emulator. Therefore one of the following is wrong...

    1. You are testing against a FL3.0 device
    2. Using FL3.0 in device central

    You need to move to FL3.1 which have htmlText with img tag support.

    Regards,

    Mark
    www.flashmobileblog.com

    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Mar 23, 2009 6:16 AM
    Thanks Mark, I believe I will have to do more testing specific to my device and get back to you on my findings.
    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Mar 24, 2009 12:29 PM
    Hi Mark,

    I checked my settings. I installed the FlashLite_DP_WM6Professional_EN.cab from Adobe Labs on my device.

    In my publish settings in my FLA they are set to Flash Lite 3.1.

    Bobby
    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Mar 25, 2009 6:52 AM
    Hi Bobby,

    I have uploaded the test SWF that I have verified, www.flashmobileblog.com/bobby.fla

    You can package that with the mobile packager and test it out. Further, this should work on the FL3.1 profiles in Device Central so please test that also.

    What type of device do you have?

    Mark
    |
    Mark as:
  • Currently Being Moderated
    Community Member
    May 9, 2009 10:06 AM

    Hi,

     

    The Sony Ericsson device is not supported by the Flash Lite 3.1 Distributable Player.  The query above relates to the security model present only in the Distributable Player.

     

    Regards,

     

    Mark

    |
    Mark as:
  • Currently Being Moderated
    Community Member
    May 10, 2009 4:36 AM

    Hi,

     

    It seems that I only looked back as far as the last person posting, sorry!

     

    We update the supported devices at this url, and because the X1 is a unique device from a single OEM I can't guarantee that our WM6.1 binary will work on it.  That's why we certify devices :-)

    http://labs.adobe.com/wiki/index.php/Distributable_Player:Supported_De vices

     

    Can you confirm that your content works on WM devices within the supported list?

     

    thanks,

     

    Mark

    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Jun 29, 2009 4:36 AM

    Can you try specifying the full path when using loadclip?

    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Jul 2, 2009 3:44 AM

    Where are you loading the images from?

    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Jul 23, 2009 6:19 AM

    Hi,

     

    Sorry for the delayed response here.

     

    I had a chance to look at your code today and found the issue as demonstrated in the following example, which is compatible with WM6.

    ou'll see that you had two problems:

     

    1.  You were trying to reuse the moviecliploader class within the same frame for actions that had not completed.  This works on the desktop because of the hardware speed, but on a mobile phone things run slower and sometimes we queue up the requests as well.

     

    2.  The GIF image that you are trying to load fails on the HTC Diamond, and I presume that this means it's not supported.  Device Central reports that GIF is supported so you may want to try a different bit depth, however JPG is typically a better solution for most mobile devices for performance reasons.

     

    3.  I've split up the loading into frames to demonstrate how to create your own queue of load requests, but you could use your approach of a single frame and begin each request after the onLoad event fires for the previous.

     

    Regards,

     

    Mark

    www.flashmobileblog.com

    Attachments:
    |
    Mark as:
  • Currently Being Moderated
    Community Member
    Jul 24, 2009 4:53 AM

    I recommend JPG instead of PNG, in some tests we showed it to be 20x faster in drawing/decompressing on devices.

     

    Im not sure what happened in FL3.1 with GIF support, it seems strange that it should break but it could be something to do with our hardware acceleration efforts.

     

    The team will look into this.

     

    Mark

    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points