PDA

View Full Version : Combo Boxes



wlipira
April 2nd, 2002, 08:20 AM
Hello.
I am trying to create a set of 3 combo boxes. The 1st on (on the left), when an item is selected, would set the 2nd combo box properties to match that item, which in turn would set the third item properties.

Box 1 - Book---Box 2 - Chapter---Box 3 - Verse
Genesis 10 3

Dynamic Text Box
-------------------------------------------------
| |
| Contents of Verse |
| |
-------------------------------------------------

Any ideas?

Thanks,

W

I am not Jubba
April 2nd, 2002, 09:19 AM
do you want them to be boxes where people input what "Book, chapter, and verse" they want?

wlipira
April 2nd, 2002, 09:24 AM
They will be pre-made. Loading information from a database.

Montoya
April 2nd, 2002, 01:55 PM
Scenario I or Scenario II?

I. Are users selecting from each box?

box1: (user selects Genesis)

box2: (user selects Chapter)

box3: (user selects verse)


II. ...or do you have some canned verses and you're hoping for

box1: (user selects Genesis)

upon selection of Genesis box2 and 3 bring up a choice.

If your answer is I...

assign variables to boxes:

book=cb_instance.getselecteditem();
chapter = cb_instace.getselecteditem();
verse=cb_instance.getselecteditem();

then, I would change my sql statement to reflect their choice (if that is what you're trying to do..) concatenating your boxes...
book + chapter + verse (being variables)

good luck!

wlipira
April 2nd, 2002, 02:02 PM
Dupe...Sorry

wlipira
April 2nd, 2002, 02:02 PM
My request is more like selection II.
It is more like when box 1 is selected box 2 is changed (default chapter one - hence box 3 is selected to verse 1 default).
So when a user changes box 2 then box 3 is updated.
Then when box 3 is changed then there will be a go (request-whatever name) button. When that button is clicked then the approriate verse will be displayed in the TextField.

As you may know I am just learning actionscripting. I have used flash in the past for the simplest things.
Thanks to everyone who has (and hopefully will) taken the time to help me. I know that once my knowledge grows, I will be able to do the same for others.

Montoya
April 2nd, 2002, 02:11 PM
I guess I left out.... If your answer is II...

If it is more like II, I would say: Why have three combo boxes?

I would have one, maybe two..

you could have one that is generated from a query of available verses.. that way, the combo box will list all available verses, and you could choose from there...

I do realize that this could create a large list.... so, you could do two boxes.. one for Book and the other with all verses available for that book.


All in all.. this would turn into data handling in Actionscript, and Im not the best person to teach you that.. I do this kinda thing in Ultradev

wlipira
April 2nd, 2002, 02:17 PM
Well,

I guess you know by know I am creating a Bible Application. So I do need to break it down by book, chapter, then verse.

Besides, I think that this project's code would be able to be used by all developers.
I will be placing the source code online once the project is done, with credit of course, going to those whom have helped me out with this.
I want to show people that there is so much that can be done with Flash (whether 5 or 6), and that we are a tight-knit community.

Cheers....