listbox to respond to another listbox

Reply

Join Date: Jul 2005
Posts: 12
Reputation: ozeona is an unknown quantity at this point 
Solved Threads: 0
ozeona's Avatar
ozeona ozeona is offline Offline
Newbie Poster

listbox to respond to another listbox

 
0
  #1
Aug 3rd, 2005
hi

I have a main listbox, which the content is in form of dynamic arrays. Upon click on some of the item in the listbox, some other arrays are suppose to appear in another listbox, by checking that both of them have the same "title".

I was thinking of using listener to listen to the main listbox, but it does not work. Can anyone suggest a better way to solve this?

btw, i saw one tutorial at www.flash-mx.com its something like the dependable combobox tutorial, but the arrays are 2 different arrays, unlike the one in the tutorial.

thanks
Reply With Quote Quick reply to this message  
Join Date: Mar 2007
Posts: 59
Reputation: PVBert is an unknown quantity at this point 
Solved Threads: 5
PVBert PVBert is offline Offline
Junior Poster in Training

Re: listbox to respond to another listbox

 
0
  #2
Mar 21st, 2007
With:

Graphics and Multimedia Syntax (Toggle Plain Text)
  1. Private Sub List1_Click()
  2. MsgBox List1.ListIndex
  3. End Sub
You can detect which item is clicked

With
Graphics and Multimedia Syntax (Toggle Plain Text)
  1. List2.AddItem "blablabla"
you can add an item to the second listbox.

Or:
Graphics and Multimedia Syntax (Toggle Plain Text)
  1. Private Sub List1_Click()
  2. Select Case List1.Listindex
  3. Case 0
  4. msgbox "1st item"
  5. Case 1
  6. msgbox "2nd item"
  7. Case 2
  8. msgbox "3th item"
  9. Case Else
  10. msgbox "oeps dunno?"
  11. End Select
  12. End Sub
But here you have to know how many items are in List1!
Last edited by PVBert; Mar 21st, 2007 at 7:58 pm.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Graphics and Multimedia Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC