# Launching lightwindow from AS3 with xml

**URL:** <https://forum.kirupa.com/t/launching-lightwindow-from-as3-with-xml/283144>\
**Category:** flash\
**Created:** [March 3, 2009, 3:06am UTC](https://forum.kirupa.com/t/launching-lightwindow-from-as3-with-xml/283144 "2009-03-03T03:06:19Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![squarelight](https://avatars.discourse-cdn.com/v4/letter/s/f475e1/32.png) [@squarelight](https://forum.kirupa.com/u/squarelight)\
**Post date:** [March 3, 2009, 3:06am UTC](https://forum.kirupa.com/t/launching-lightwindow-from-as3-with-xml/283144/1 "2009-03-03T03:06:19Z")

</div>

I’d like to replace my current functionality of just launching a new url in a new window to loading a .swf in lightwindow. I’ve seen a previous post on this but I was having trouble following it.

My current function looks like this:

protected function clickHandler(me:MouseEvent):void {  
trace("PortfolioItem::click ");  
var request:URLRequest = new URLRequest(“http://” + \_url);  
try {  
navigateToURL(request, ‘\_blank’);// second argument is target  
} catch (e:Error) {  
trace(“Error occurred!”);  
}  
}

I think I am supposed to add the ExternalInterface class to help adapt the lightwindow javascript to work within flash.

Going crazy trying to figure this out…
