11/27/2009 7:08:51 AM
Title:
avoid application view
hi, i m loading source for swf at run time.. what my problem is loading b/w 2 sources its shows blank application background like 1second...its does not show any blank page while loading source what can i do for that?
11/27/2009 7:49:43 AM
are you using image component to load swf in flex ? it does not contain a background so its blank , You can keep the image component in some other component like canvas or Vbox etc and set background color to white . So when image is loading it will show the canvas white background with border if you set that also . And on loading complete os that image it gets displayed in that box .
11/27/2009 7:54:22 AM
i m using swf loader ,without show that empty box or application we can not load the swf?
11/27/2009 8:16:17 AM
you can set visible to false while setting source or by default and then make it visible on complete event.So there will be no empty box until file gets loaded .
11/27/2009 8:26:24 AM
this code will set visibility after swf is loaded :
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" width="300" height="300" backgroundAlpha="0">
<mx:Script>
<![CDATA[
private function showMe(evt:Event):void{
evt.target["visible"]= true;
}
]]>
</mx:Script>
<mx:SWFLoader visible="false" source="testSwf.swf" complete="showMe(event);" >
</mx:SWFLoader>
</mx:Application>
11/28/2009 1:33:11 AM
any way its shows the same blank page at loading time... is any other solution for avoid this problem?
11/28/2009 11:18:31 AM
do you mean application background by blank page? the above code by ArmStron work fine for me. Now my swf component shows only after loading image no blank component background.
Thanks ArmStron
11/30/2009 5:06:30 AM
no i mean it i have 6 swf sources in xml and i m loading the xml dynamically into swf loader k ... the data's loaded one by one from xml ...time gap for loading one data to another data the application background visualized blank page....i asked solution for that problem....
11/30/2009 6:02:02 AM
pre-load all the files first then start showing them one by one , by preloading them the slides will come into browser cache and load instantly.
5/31/2011 10:45:37 PM
just place a text field on the stage