944,154 Members | Top Members by Rank

Ad:
Aug 3rd, 2005
0

listbox to respond to another listbox

Expand Post »
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
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
ozeona is offline Offline
12 posts
since Jul 2005
Mar 21st, 2007
0

Re: listbox to respond to another listbox

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.
Reputation Points: 10
Solved Threads: 5
Junior Poster in Training
PVBert is offline Offline
60 posts
since Mar 2007

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Graphics and Multimedia Forum Timeline: Help resizing bitmaps
Next Thread in Graphics and Multimedia Forum Timeline: flash problem





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC