Timmy
Timmy

Reputation: 12828

Open source popup/panel for actionscript 3?

Does anybody have a solution for a popup (for a help panel)? thanks. this is in pure as3.

Upvotes: 1

Views: 647

Answers (2)

Todd Moses
Todd Moses

Reputation: 11029

To use ActionScript 3 to open an HTML popup do something like this:

var url:String = "javascript:openNewWindow('test.html','thewin', 'height=200,width=250,toolbar=no,scrollbars=no')";
var request:URLRequest = new URLRequest(url);
try {
  navigateToURL(request, '_blank'); // second argument is target
} catch (e:Error) {
  trace("Error occurred!");
}

I am not sure what you mean by pure ActionScript. Do you want the pop-up to be in the SWF? If so then you can create a sprite and show or hide it based on an event.

Upvotes: 1

Related Questions