|
Thanks for testing it. I forgot to add the flex/framework.swc to
my library source :P From: This is working for me: On 5/29/06, Bjorn
Schultheiss < [EMAIL PROTECTED]>
wrote: Hi, Can
someone please tell me where I'm going wrong here? I
am trying to load a background image in my application and it will not display. Here
is the code package
{
import flash.display.Sprite;
import flash.display.StageAlign;
import flash.display.StageScaleMode;
import flash.events.Event;
import flash.utils.*;
import flash.display.MovieClip;
import com.zuki.view.Preloader;
import flash.display.Bitmap;
public class zuki extends Sprite
{
public var className:String = describeType(this)[EMAIL PROTECTED]();
[Embed(source="assets/image/bgswf.gif")] private var appBg:Class;
private var preloader:Preloader;
private var size:int;
public function zuki()
{
trace('zuki');
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP;
var bg:Bitmap = createImage('appBg');
addChild(bg);
// this trace message below is not appearing in the
console at all
trace('bg: '+bg);
bg.width = 950;
bg.height = 600;
bg.x = 0;
bg.y = 0;
preloader = new Preloader();
addChild(preloader);
preloader.x = 300;
preloader.y = 100;
}
private function createImage(embedLinkage:String):Bitmap
{
trace('createImage');
var imgName:String = className + "_" + embedLinkage;
trace('imgName: '+imgName);
var imgRef:Object = getDefinitionByName(imgName);
var img:Bitmap = new imgRef();
return img;
//return imgName;
}
} } Bjorn Schultheiss Personalised Communication Power 3205,
VIC Australia ((------------This transmission is confidential and intended
solely for the person or organization to whom it is addressed. It may contain
privileged and confidential information. If you are not the intended recipient,
you should not copy, distribute or take any action in reliance on it. If you
believe you received this transmission in error, please notify the
sender.---------------))
SPONSORED
LINKS
YAHOO!
GROUPS LINKS
|

