Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Article how to validate records in grid
Message
 
 
To
14/06/2002 08:48:07
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00668180
Message ID:
00668493
Views:
18
Great, thanks a lot for sharing. I'm so envious of all you with VFP7. We haven't switched yet and I don't know, when we will :((((

>Hello Nadya.
>
>See Re: Validation for Grid Thread #630571 Message #630572
>
>Actually, with VFP 7.0, it is much easier to do this sort of thing. This is all you need in BRCC:
>
>
>LPARAMETERS nColIndex
>WITH This
>  IF INLIST( .RowColChange, 1, 3 )
>    *** If we are trying to move to a new row
>    *** validate the current row
>    IF NOT EOF( .RecordSource ) AND RECCOUNT( .RecordSource ) > RECNO( .RecordSource )
>      *** Do not allow the move if the validation fails
>      IF .ValidateCurrentRow()
>        *** peachy keen go ahead and move off the row
>        *** and make sure the highlight gets reset
>        IF !.lAbout2LeaveGrid
>          .nRecNo = 0
>        ENDIF
>      ELSE
>        NODEFAULT
>      ENDIF	
>    ENDIF
>  ENDIF
>ENDWITH
>
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