PDA

View Full Version : image button to alert box


chrish
04-12-2006, 08:07 PM
Hi all

Total newbie looking to link an image generated button (covert to symbol) to open an alert box once clicked. I have been using the following codes for normal UI buttons:

import mx.controls.Alert;
myListener = new Object();
myButton.addEventListener("click", myListener);
myListener.click = function() {
Alert.show(
"You have made an illegal operation !! Your computer will now explode.",
"Terminal Error",
Alert.OK | Alert.CANCEL,
_root, Alert.OK);
};


Which works great, but as the main image is a map I simply want a transparent button that could be pressed to open up an alert box or window component.

Any advice would be great.

Many Thanks

Chris