Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Grid navigation
Message
 
 
To
11/12/2009 14:38:22
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
01438689
Message ID:
01438691
Views:
65
>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.

Did you try this code before skip and after?

Or may be you can just call some common method from ARCC and from KeyPress ?
If it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform