all groups > flash actionscript > july 2004 >
You're in the

flash actionscript

group:

Alert box empty


Alert box empty Lone Jet
7/31/2004 8:00:17 PM
flash actionscript:
The code below genereates an empty alert box without my specified messages, just an OK button. Is this another bug?


Re: Alert box empty derobinson
8/1/2004 7:05:28 PM
You need to make sure and import the Alert controls at the top of your AS:

import mx.controls.Alert;

Then call it like this when you need it:

Alert.show("Login Failed!", "Login");


Hope that helps!
/david
Re: Alert box empty Lone Jet
8/1/2004 7:07:57 PM
I tried that and got the same result. The code I used came from Ben Forta's example on Macromedia.com.
Re: Alert box empty derobinson
8/2/2004 2:48:46 AM
No, sorry. That worked for me.

You know, you probably need to drag an instance of the Alert box to the stage,
then just delete it so that it is in your Library for it to be available to
script at compilation. Have you done that by chance?

Otherwise, I'm assuming you;re using MX 2004. Is this a project you happened
to have started in a previous version of Flash? Version 1 components and
version 2 components don't play well together and I've seen things just stop
working if you try to use both.

Let us know if any of that works!
/david
Re: Alert box empty Lone Jet
8/2/2004 2:33:28 PM
That did it. Dragging onto the state and deleting was enough apparently to include what was missing.

Thanks.
Re: Alert box empty derobinson
8/2/2004 9:09:32 PM
great! glad it worked for you.

AddThis Social Bookmark Button