
Outline Control Q? - VB 3 Pro
I have a problem with the syntax of the PictureClick event in the Outline
Control.
When you double click the control itself you get the following declaration:
Sub Outline_PictureClick (ListIndex As Integer)
Sub End
Ok, so you pop some code into PictureClick. Such as,
txtDisplay.Text = Outline.List(ListIndex)
Then you notice that if you Click on one item, so that it's index = ListIndex,
*then* PictureClick on another item the PictureClick code executes for the
*first* item, not the one you clicked on.
Fine, if in doubt read the manual, not a problem.. But when you check out the
Pro help or manual you are told:
sub Outline_PictureClick([Index As Integer,] I As Integer)
and a Remark of:
This event passes I, the index of the item whose picture was clicked.
*Now* I'm confused. Is I equivalent to the ListIndex of the control
declaration? What is the optional Index parameter about? Why can't I add
'Index As Integer' to the control declaration? Why doesn't ListIndex in the
control declaration seem to refer to the item clicked on?
All I want is for a click on an item's Picture to refer to *that* item. Can
someone explain how to achieve this to me?? What am I missing?
Thank you for your attention.
Duncan
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Duncan McCardle
CRC for Tropical Pest Management Telephone : +61 7 365 1859
Gehrmann Laboratories Facsimile : +61 7 365 1855
The University of Queensland
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~