Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Event firing order problem in grid
Message
From
29/05/2003 13:33:28
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Title:
Event firing order problem in grid
Miscellaneous
Thread ID:
00794051
Message ID:
00794051
Views:
49
In a navigation grid I am trying to keep the active row a few rows below the top. I also want a double click to change focus to page2 where editing occurs.

To accomplish it I initially did this:

1) In AfterRowColChange method I call a method that moves row to new position.
2) In DoubleClick() focus changes to page2.

Unfortunately, when person double clicked, AfterRowColChange fires before DoubleClick. As a result, when the second click occurs a different row is under the mouse, and the wrong record comes for edit.

To solve the problem, I was advised to place a delay in This.Click() for _DBLCLICK seconds while checking INKEY(.01,'M'). If a new click came in that time, This.Doubleclick is called. If the delay elapses normal behavior resumes including AfterRowColChange.

Now the problem is if user quickly clicks on two rows, meaning to navigate, the call from the INKEY loop fires DoubleClick and incorrectly send form to page2. I tried checking This.ActiveRow, but it doesn't seem to change while you are within the Click event!

Any suggestions?

Thank you very much.

Alex
Next
Reply
Map
View

Click here to load this message in the networking platform