Click to See Complete Forum and Search --> : Data Grid
Phobos
Aug 26th, 2000, 08:49 AM
I am customizing the Datagrid control so that it validates the data entered by the user. It will validate whether the value entered is long the database field size (eg if Field Size was 5, if they entered 6 it would warn the user of this then return to that column). I have it working when the user moves from column to column, need help on how to do it when moving from row to row.
Anyone any ideas ? Urgent !!!!
davidrobin
Aug 28th, 2000, 03:17 PM
When moving from column to column you are moving within the same database record, when moving from row to row you are moving from record to record. Try using the WILLMOVE and MOVECOMPLETE events of the recordset. (You will have to check on the correct name of the events, I am at home at the moment and do not have VB on my home machine to check the correct event names.) One fires as the recordset is about to move and gives you the chance to cancel the move, the other fires after the move is complete (tricky stuff eh!).
Phobos
Aug 29th, 2000, 10:05 AM
Thanks David, I'll give it a try.
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.