A Flash Developer Resource Site














Internet Commerce

Partners & Affiliates














Developer Channel

internet.com


Featured Flash FLA
Gallery Downloads 11303 Flash Movies | 7 New Flash Movies Added
What's New | Top 100

Featured FLA

» Author: Nitin Tikhe
» Title: Cart
» Description: This Animation Tut is a fun and useful for kids below 15 years. Watch the Flag, Doors, Stick and Horse movements.
» More by Nitin Tikhe


Random FLAs | Add Flash Movie
Featured Flash Site
Gallery Downloads 6008 Flash Sites | 0 New Flash Links
What's New | Top 100 Flash Site

Featured Site

» Posted in the Flash Kit Links section
» Title: Banana Swimwear
» Description: This is a banana swim wear interactive catalog we designed and animated in Flash


Random Links | Add your own Flash Related Links
Flash Tutorials 1255 Tutorials 7 New Tutorials Added!
What's New | Top100

» Make flash video player for broadcasting live streaming video / TV on website
» How to convert the project file of Flash Demo Builder 2.0 into FLV file
» FLV to PSP for Mac - How to convert YouTube video to PSP on mac
» How to Convert FLV to MP4 for Playback on iPod
» how to download and convert youtube video to AVI with Leawo Free FLV converter
» Flash Multi-player Game Tutorial - TicTacToe
» How to make Flash elearning tutorials with screen recorder?
» Fader API:Slideshow with MovieClips on stage
» How to convert MS PPT file into an FLV File
» Unknown Tag: Title10
Random Tutorial | Add Site

Network Design Manager
The Computer Merchant, Ltd
US-VA-Hampton

Justtechjobs.com Post A Job | Post A Resume


Tutorials Home What's New Top Rated Submit myTutes Random!

Search Tutorials


Tutorials Tutorials » Interactivity

Categories Accessing Multiple Buttons in UI Components #2 Message Box
Author: Thomas Watson | Website: http://hikercentral.net |

 
Page 1
1 2 next»

This is sort of a follow-up to my previous tutorial on CGI Forms with Flash MX and the UI Components Set#2. I used the message box in that tutorial, but only with a single button. An email from a reader of that tutorial prompted me to take a closer look at the message box and how to use it with multiple buttons.

First if you don't have Components Set, go here. and get it. Install using the new version of Macromedia Exchange, which you can also download from that page.

Macromedia has issued very sparse documentation on these components, I guess leaving it up to us users to figure out how to use them. Perhaps one day they'll issue some tech notes or something, but in the meantime, here's what I've discovered. And I'll say up front, this may not be the most efficient way, but it works. I saw some hints along the way that makes me think there could be another way-- that there could be some methods that provide more direct access, but none that I could get to work.

timeline First here's what my timeline looks like. Just four layers. One for "actions", one for "functions", one for the "message box", and one for a dynamic text box that will display some feedback.

This could all be done in a couple of frames, but I like a little room to move around in. Some of the layers could be combined as well, but again, I like to have my projects organized so that I know where everything is, and can find them six months from now!

Go to frame 5 in the "action" layer and add a keyframe. For the action in that frame add stop();.

Next, drag a message box from the "Components" panel on to the stage and open the "Properties" panel. Just fill what you want for "Title", "Icon", and "Message."

Now click on the icon on the "Buttons" line to open the dialog which allows you to add buttons to the message box. For this tutorial I added two more to the existing one, changing it's name in the process. My buttons are "Yes", "No", and "Maybe." Next type in a name for your "close handler." This can be any name that makes sense to you. I called my "myCloseHandler."

After filling in the properties, be sure and give this message box an instance name. We have to do this to be able to talk to it in action scripts. I called this one "myBox."

Next, lock and hide the message box. In the center of the stage, right where the message box displays, add a small dynamic text box. Give it an instance name (mine is "ansrBox"). For this test, we don't need to assign a variable, although you likely will in "real" applications.


Next Page->

1 2 next»

» Level Intermediate

Added: : 2002-05-17
Rating: 7.32 Votes: 12
Hits: 2072
» Author
Tom Watson is a Flash developer currently residing in Nashville, Tennessee. He's been an independant contractor in the computer business since 1989, working on web projects since the web was introduced to the Internet in 1994.
» Download
Download the files used in this tutorial.
Download (106 kb)
Get conversion and unzipping tools for PC and Mac here!

» Forums
More help? Search our boards for quick answers!

Please rate this tutorial, 10 is the top rating, you can also click the comments link to read/write a review.
10 9 8 7 6 5 4 3 2 1
Read or Post Comments