Actionscipt not working in IE 7 passing Vars

I am having a strange problem with my Actionscript not working in PC IE7. Everything works fine in Mac Firefox and safari.

I am passing a variable from the html using swfObject, loading it in flash, populating a movie clips text field. However, the field shows “error” in IE7.

Also with the actionscript I am positioning the movieclip to stage right. When I remove that code everthing appears to work fine. However, positioning to the right is a must for my design. Why does IE7 act differently. I have spent way to long googling a solution to no avail. Can anyone shed light on this for me?

Sample:

My actionscript code on frame1:


maskbox.width = stage.stageWidth;
backgroundclip.width = stage.stageWidth;
rightside.x = stage.stageWidth;
slogan.x = stage.stageWidth;
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;

function resizeListener (e:Event):void {
maskbox.width = stage.stageWidth;
backgroundclip.width = stage.stageWidth;
rightside.x = stage.stageWidth;
slogan.x = stage.stageWidth;
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;
}

var allFlashVars:Object = LoaderInfo(this.root.loaderInfo).parameters
slogan.InstanceName_6.text = String (allFlashVars.pagetitle);
stage.addEventListener(Event.RESIZE, resizeListener);

logo.addEventListener(MouseEvent.CLICK, myBtnClicked);

function myBtnClicked(e:MouseEvent):void {
var url:String = "../index.php";
var request:URLRequest = new URLRequest(url);
try {
navigateToURL(request);
} catch (e:Error) {
trace("Error occurred!");
}

}

My swfObject code:


<script type="text/javascript">
		// <![CDATA[

		var so = new SWFObject("../BPPWsubheader3.swf", "fwa", "100%", "100%", "9", "#000000");
		so.addVariable("flashVarText", "this is passed in via FlashVars");
		so.addParam("scale", "noscale");
		so.addParam("wmode","transparent");
		so.useExpressInstall('../expressinstall.swf');
		so.addVariable("pagetitle","Areas of Practice");
		
		so.write("header2");

		// ]]>
	</script>