PRB: Mouse & Click Events Behavior in List Box and Grid Differ
ID: Q156870
|
The information in this article applies to:
-
Microsoft Visual FoxPro for Windows, versions 3.0, 3.0b, 5.0, 6.0
SYMPTOMS
The Mouse and Click events do not fire on same areas of the object. The
Click event ignores clicks to the scroll bar.
STATUS
This behavior is by design.
MORE INFORMATION
The behavior of the Mouse and Click events differ. The Click event executes
after clicking on the item itself; however, the Click event ignores clicks
to the object's scroll bars. For example, clicking on an item listed in a
list box triggers the Click event.
Conversely, Mouse events react to both clicks on the object and the scroll
bars of the object. For example, consider a list box and its scroll bars. A
MouseUp or MouseDown event fires after clicking the contents of the list
box or the scroll bars of the object.
This behavior occurs with grid and list box objects.
Steps to Reproduce Behavior
- Create a form called Test.
- Place a list box object on the form.
- Right-click the list box and start the Builder.
- Under the List Items tab, change the "Fill List with" box to "Data
entered by hand." Enter in three values for three rows. Choose the OK
button.
- In the MouseUp, MouseDown, and Click events of the list box enter the
following command:
WAIT WINDOW PROGRAM()
- Run the form and click on the scroll bars. Only the MouseUp and
MouseDown events fire. Now click on a row of the list box. The Click,
MouseUp, and MouseDown events all respond.
Additional query words:
kbdsd VFoxWin
Keywords : kbVFp300 kbVFp500 kbVFp600 FxprgClassoop FxprgGrid
Version : 3.00 3.00b 5.00
Platform : WINDOWS
Issue type :