-
help i cannot get this preloader to work
i am trying to use an external preloader for a F4V file which is kept at a HTTP address however it does not work. The preloader i am using is the standard flash template external preloader.the code is below. i think the content loader does not work with F4V files so can anyone provide an alternative script to make this work?
thank you
var contentLoader:Loader;
loadContent("http://www.my URL address");
function loadContent(url:String):void {
contentLoader = new Loader();
contentLoader.contentLoaderInfo.addEventListener(P rogressEvent.PROGRESS, loading);
contentLoader.contentLoaderInfo.addEventListener(E vent.COMPLETE, contentLoaded);
contentLoader.load(new URLRequest(url));
}
function contentLoaded(evt:Event):void {
//Optionally change to a clip holder and set progressbar visibility.
addChild(contentLoader);
}
function loading(evt:ProgressEvent):void {
var loaded:Number = evt.bytesLoaded / evt.bytesTotal;
setBarProgress(loaded);
}
function setBarProgress(value:Number) {
progressbar.bar.scaleX = value;
}
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|