Home Tutorials Forums Articles Blogs Movies Library Employment Press

Go Back   ActionScript.org Forums > Extensions and Plugins > Components

Reply
 
Thread Tools Rate Thread Display Modes
Old 06-16-2004, 12:31 PM   #1
GeckOblue
Registered User
 
Join Date: Jun 2004
Posts: 2
Unhappy Using ListBox to control timeline ???

Hello!
Nice Fourm!

Here is my dilema:
I am trying to use a listbox component to take the user to different frames of the timeline.

For example:
The UI Component ListBox, has in it the labels, 'story 1', 'story 2', and 'story 3'. In the main scene that contains this component, there is the text of story 1 on frame 1, the text of story 2 on frame 2, and so on. The ListBox itself doesnt need to retrieve from any external source information, the text is already on the scene on different frames. All I want the buttons on the listbox to do is take the user to the different frames (corresponding with the name of the label/button).

This seems simple enough, but so far there doesnt seem to be any way to add actions to the individual rows/labels/buttons in the ListBox component. Under behaviors I was able to add on (change) {

//Movieclip GotoAndPlay Behavior
this._parent._parent.gotoAndPlay("2");
//End Behavior


but of course this applies to the whole component not to an individual button in the listbox component, so that when I click on 'story 5', it will still go to frame 2...

you get the idea.

SO how do i point the individual buttons in the component to go to and play different frames? (ListBox button: 'story 7' to go to frame 7, etc.)
I know I must seem dumb, its probably very simple...
but please give me a hand here.
Thanx,
GeckOblue
GeckOblue is offline   Reply With Quote
Old 06-16-2004, 06:57 PM   #2
GeckOblue
Registered User
 
Join Date: Jun 2004
Posts: 2
Cool Nevermind


thanx for the help...
got the nfo at flashkit.com and #flash on undernet (irc)
GeckOblue is offline   Reply With Quote
Old 12-10-2004, 01:16 AM   #3
getpaid2share
learning to walk in flash
 
Join Date: Dec 2004
Location: Los Angeles, California
Posts: 6
Send a message via Yahoo to getpaid2share
Arrow

Quote:
Originally Posted by GeckOblue

thanx for the help...
got the nfo at flashkit.com and #flash on undernet (irc)
You got the answer where? ... Probably a fat chance that you will come back and clarify where you got the answer to this question, I'm looking for the Same answer. flashkit.com and "#flash????" on undernet (irc) ????

Could you write that in english for those of us who arent as intelligent
Or if anyone else Does know the answer to this question, Could you be so kind as to share it, not just for me, but for all of those who like Geckoblue and myself, would love to know.
getpaid2share is offline   Reply With Quote
Old 12-10-2004, 02:54 AM   #4
annexion
I make out with chicks
 
Join Date: Oct 2002
Location: NYC
Posts: 1,586
Default

PHP Code:
listBox.dataProvider=[{label:"Story 1",data:"s1"},{label:"Story 2",data:"s2"},{label:"Story 3",data:"s3"}];

var 
lbListener={};
lbListener.change=function(evt){
timeLineReference.gotoAndStop(evt.target.selectedItem.data);
}
listBox.addEventListener("change",lbListener); 
__________________
www.perpetuated.com
annexion is offline   Reply With Quote
Old 12-10-2004, 05:09 AM   #5
getpaid2share
learning to walk in flash
 
Join Date: Dec 2004
Location: Los Angeles, California
Posts: 6
Send a message via Yahoo to getpaid2share
Default .... still not working... but im sure there is a Solution.

Quote:
Originally Posted by annexion
PHP Code:
listBox.dataProvider=[{label:"Story 1",data:"s1"},{label:"Story 2",data:"s2"},{label:"Story 3",data:"s3"}];

var 
lbListener={};
lbListener.change=function(evt){
timeLineReference.gotoAndStop(evt.target.selectedItem.data);
}
listBox.addEventListener("change",lbListener); 
Thanks annexion ....

That didnt exactly work out for me. Let's see if I can try explaining things a lil better.

I have the following instances in my movie.

A listBox = productList_lb
A Product MovieClip = products_mc

Inside of the products_mc I have 4 frames with frame lables to help with navigation : 1 = blank 2 = coffee 3 = tea 4 = candles.

In my productList_lb, I have 4 Labels. Labels that I filled manually in the component inspector. Those labels are: 0= Welcome 1 = Coffee, etc..

naturaually what I want to do, is script it so that clicking on Coffee, will perform this action ->>
PHP Code:
_root.products_mc.gotoAndStop("coffee"
Now, I tried your suggestion annx, and First, the "dataProvider" simply filled my listbox with Welcome from top to bottom.

So I deleted that line, and re-filled my labels out mannually... and then the rest of the code, still didnt do anything.

The "blank" frame has a page that says "Start Shopping" .. it's tied to the Welcome label in my listbox.

So far, with everything I've tried, nothing moves my movie off that "blank" frame.

Maybe I should try sending the .fla to someone?? ...

I hope someone is able to help answer this question.

There is always a solution to every problem.

Last edited by getpaid2share; 12-10-2004 at 01:32 PM.
getpaid2share is offline   Reply With Quote
Reply


Thread Tools
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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump


All times are GMT. The time now is 09:06 PM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.