Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do you work with combox..?

Status
Not open for further replies.

andsgiant

Technical User
Mar 9, 2003
14
ID
I have a scene with a combobox on frame: "cmbx"

I would like to open another frame.. or display the text on the other frame within the scene, when user select the option/choices of the cmbx... ?

How could i do it with actionscript, please help???

Many thanks for your help.
andre
 
tx Maria for the zipped file, but...

what i wanna do was the frame(text) loaded right after on release the opt choosen. (triggered with the opt)

I found this code from another thread.
===================================================
function comboFunction(component){
varName = component.getValue();
trace(varName);
if (varName == "data2") {
getURL(" "_blank");
}
};

===================================================
PS: I have no idea when building codes from scratch.
 
What version of flash are you using? It is different between MX and MX2004.

Wow JT that almost looked like you knew what you were doing!
 
I think ..yeah, it's like jumpmenu....>> Marianowo.

I use Flash MX.. pixl8r, btw .... the function i posted earlier was from your code/thread..! thanks >> pixl8r.

-many thanks for all your contribution guys, i really have no idea when building code from scratch.

 
Add a frame label(s) to your target frame(s). Do this by clicking on the (keyframe) and in the properties palette fill in the "Frame Label" box.

Then simply modify the code to something like this:

Code:
function comboFunction(component){
    varName = component.getValue();
    trace(varName);
    switch (varName){
       Case "var1" :
          gotoAndPlay("nameOfLabel1");
          break;
       Case "var2" :
          gotoAndPlay("nameOfLabel2");
          break;
    }
};

Hope that helps!

Wow JT that almost looked like you knew what you were doing!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top