Loading with variable

All rgiht,

here i’s a easy one ( for you not for me) . On the stage I have buttons that should load different swf. Usually I should put all the code on a single “action” layer. But, it is not what I want to do I have a movie clip that I want to play before the loading ( button click - movie clip - loading the swf).

So i put this code at the en of the movie clip:

var mLoader:Loader = new Loader();
var swf;
var mRequest:URLRequest = new URLRequest(swf);

function startLoad()

mLoader = new Loader();
mLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, onCompleteHandler);
mLoader.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, onProgressHandler);

function onCompleteHandler(loadEvent:Event)
function onProgressHandler(mProgress:ProgressEvent)
var percent:Number = mProgress.bytesLoaded/mProgress.bytesTotal;

and on the main stage I got

import flash.net.URLRequest;
import flash.display.Loader;
import flash.events.Event;
import flash.events.ProgressEvent;

var swf;

function printCLICK(event:MouseEvent):void {
	swf = "print.swf";

print_btn.addEventListener(MouseEvent.CLICK, printCLICK);

So I get Parameter url must be non-null. How can I fix this…