Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Grid navigation
Message
From
11/12/2009 14:38:22
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Grid navigation
Miscellaneous
Thread ID:
01438689
Message ID:
01438689
Views:
105
I have some code written that is supposed to update a business class when the user presses enter in a textbox. I use the KeyPress method and look for keycode 13. What the program is supposed to do is to go to the next row in the grid, and set the focus back to the textbox. The grid is bound to the same business object I am updating, and when the row changes in the grid, a details view also gets updates.

My problem is that the AfterRowColChange method is not getting fired when I press enter in the textbox. I advanced the cursor and refreshed the grid, but because the focus has not been set to the grid, the AfterRowColChange is not fired.

How do I set the focus to the grid after I press the enter key?

The grid name is errorGrid.

I tried
errorGrid.SetFocus()
errorGrid.Column1.SetFocus()

But this does not fire the AfterRowColChange.
Next
Reply
Map
View

Click here to load this message in the networking platform