Flash Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsWeb DesignFlash Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old February 25th, 2004, 03:28 PM
ox4dboy@comcast ox4dboy@comcast is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Posts: 1 ox4dboy@comcast User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
::| How to Make Pull-Down Menus in Flash | ::

I need to build a very simple pull down menu in flash, much like a html pull down menu. I thought this was a very common task, but I cannot find a tutorial or a way to do it. I need it to be just like the "Forum Jump" "Please Select One" pull down menu at the bottom of the forum index here at Devshed. Or just like the "[Font]" "[Size]" and "[Color]" pull down menus above this message if you are writing a reply. I need it to look and function like that, but be done in Flash.

I need the menu to have a few items, for example, Item 1, Item 2, Item 3, Item 4, and then once a user selects an item from the pull down menu and releases the mouse button, they are taken to a specified url which is unique for each item in the pull down menu list.

Is this really all that hard? Why can't I find a simple tutorial for this? I am using Flash MX 2004, but it has been about 2 years since I have been involved in Flash development...I am a good bit rusty. Can someone please help out, or point me to a tutorial.

Reply With Quote
  #2  
Old February 26th, 2004, 04:46 AM
Kryo's Avatar
Kryo Kryo is offline
WOO!!! I'm a member!!!
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: Uk
Posts: 95 Kryo User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 h 10 m 49 sec
Reputation Power: 5
Send a message via ICQ to Kryo Send a message via MSN to Kryo Send a message via Yahoo to Kryo
There is a component called ComboBox that comes with both Flash MX and MX2004, that would do the job... Just drag it onto the stage and change the properties...
In the Labels properties enter..

00 Please select An Item
01 ---------------------
02 Item 1
03 Item 2
04 Item 3
05 Item 4
06 ...etc
07 ...etc

In the data properties enter...

00 defaultvalue
01 defaultvalue
02 item1
03 item2
04 item3
05 item4
06 ...etc
07 ...etc

change the ChangeHandler to item_Select
and give the combobox an instance name (E.G... ChooseItems)
then add this (or similar) Actionscript to the first frame of your movie...

PHP Code:
//This is actionscript not php...
function item_Select() {
    if (
ChooseItems.getValue() == "item1") {
        
gotoAndStop(2); //Change this line to what you want the dropdown to do
    
} else if (ChooseItems.getValue() == "item2") {
        
gotoAndStop(3);
             }else if (
ChooseItems.getValue() == "item3") {
        
gotoAndStop(4);
             }else if (
ChooseItems.getValue() == "item4") {
        
gotoAndStop(5);
             }



Hope this helps...

Last edited by Kryo : February 26th, 2004 at 05:06 AM.

Reply With Quote
  #3  
Old February 26th, 2004, 06:08 AM
vicvos vicvos is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: South Africa
Posts: 13 vicvos User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via MSN to vicvos
Hi all,
I built this attached menu, and it works fine, but the problem with it is that once the user clicks on the link of the page they wish to view,that page opens in a seperate frame, but there is no indication on the menu as to where they are in the site. I.e. something like an underline under the word to show that they are viewing that page...
Any suggestions?
Wish I had thought of it before buliding it...

Reply With Quote
  #4  
Old February 26th, 2004, 06:19 AM
Kryo's Avatar
Kryo Kryo is offline
WOO!!! I'm a member!!!
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: Uk
Posts: 95 Kryo User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 h 10 m 49 sec
Reputation Power: 5
Send a message via ICQ to Kryo Send a message via MSN to Kryo Send a message via Yahoo to Kryo
add a dynamic textfield with a variable name, then just add the variable to the on release function...

Reply With Quote
  #5  
Old February 26th, 2004, 07:13 AM
vicvos vicvos is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: South Africa
Posts: 13 vicvos User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via MSN to vicvos
I'm still new to action scrip, could you be more specific?

Reply With Quote
  #6  
Old February 26th, 2004, 12:00 PM
Kryo's Avatar
Kryo Kryo is offline
WOO!!! I'm a member!!!
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: Uk
Posts: 95 Kryo User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 h 10 m 49 sec
Reputation Power: 5
Send a message via ICQ to Kryo Send a message via MSN to Kryo Send a message via Yahoo to Kryo
Create a new layer on the main timeline called PageStatus (or something), then created a Dynamic Textbox... In the Variable namebox in text properties input a name (PageStatus will do for example)...

Next on each item in the menu, after the getURL function type in...

PageStatus = "Overview";

Change "Overview" to whatever link is pressed, you will have to do this for every link in the menu...

Reply With Quote
  #7  
Old February 27th, 2004, 05:43 AM
vicvos vicvos is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: South Africa
Posts: 13 vicvos User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via MSN to vicvos
ok, I'll try that, thanks very much

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignFlash Help > ::| How to Make Pull-Down Menus in Flash | ::


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway
Stay green...Green IT