Apparently this preloader cannot be scripted .... its impossible? or is it? :(
i cannot get this preloader to work at all i have tried many types and forms but yet still it will not work. I have reverted back to the built in flash template sampler file , preloader for external file. What i want to do is use a preloader for a movie which is an F4V file placed on my server. I specifically want it to be an F4V file so the movie is of high quality which is important, and i know flash recognises this file. I am using the very latest version of flash CC.
Here is the standard code( and i replace the load content URL with the HTTP address of my F4V file) the preloader runs as normal and the progress bar works so it is finding my movie, however when the progress bar finishes it stops and stays static of the bar filled up 100% and it will not load or display my F4V file at all and gives an output error of unknown file type.
var contentLoader:Loader;
loadContent("http://www. my URL address");
function loadContent(url:String):void {
contentLoader = new Loader();
contentLoader.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, loading);
contentLoader.contentLoaderInfo.addEventListener(Event.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;
}
Please can somebody help me?
