|
-
September 9th, 1999, 11:15 AM
#1
OnBeforeUpdate event not fired
Hi,
I am very new to VB and using a datagrid control (VB 6). I have coded the
datagrid's OnBeforeUpdate event to perform some validation and set a value
of one of the columns in the updated row for me. If I move off of the row I
am editing by using the arrow keys or clicking on another row in the grid,
the update and OnBeforeUpdate event occur as expected. However, if I click
outside of the grid, the row gets updated, but the code I have in the
OnBeforeUpdate event does not get called.
What am I missing? Is there another event I need to catch or a property of
the datagrid I need to set? I want the automatic updating, but also want to
be able to have a piece of code executed before any updating occurs.
Thanks in advance for your help,
Therese
-
September 9th, 1999, 11:24 AM
#2
Re: OnBeforeUpdate event not fired
if you want to trap when the user "leaves" a control you can use the Validate event.
By setting the Cancel argument to true you can force the focus on the current control.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|