LOCAL llEOF, llBOF *TMT 07/21/09 llEOF and llBOF llEOF = .F. llBOF = .F. SELECT poshold GO bottom IF EOF() STORE .T. to llEOF ENDIF GO TOP IF BOF() STORE .T. to llBOF ENDIF DO case *No records at all CASE llBOF AND llEOF Thisform.cmdrelease.Enabled = .F. *One (or more) record(s) (at least one is not deleted), period CASE NOT llBOF AND NOT llEOF Thisform.cmdrelease.Enabled = .T. *All records are deleted CASE NOT llBOF AND llEOF Thisform.cmdrelease.Enabled = .F. ENDCASE GO TOP IN poshold Thisform.Closable=.F.I could tighten this up and just have...
DO case *One (or more) record(s) (at least one is not deleted), period CASE NOT llBOF AND NOT llEOF Thisform.cmdrelease.Enabled = .T. ENDCASEsince that was the only condition that made the cmdRelease Enable to be True... (that we have at least ONE record that is not deleted).