WITH This IF .lValidatingRow NODEFAULT ELSE .nRecNo = RECNO(.RecordSource) ENDIF ENDWITHAnd this in AfterRowColChange:
LOCAL lnRec2GoTo WITH This IF .nRecNo = 0 RETURN ENDIF *** Save the current record number in case we have changed rows SELECT (.RecordSource) lnRec2GoTo = RECNO() *** Check to see if the row has changed IF lnRecNo # .nRec2GoTo *** We are validating the row we are attempting to leave...set the flag .lValidatingRow = .T. GOTO .nRecNo IF .ValidateCurrentRow() GOTO lnRec2GoTo ENDIF *** Finished with validation...reset flag .lValidatingRow = .F. ENDIF ENDWITHValidateCurrentRow is a template method that gets coded in the instance.