IF This.oBizObj.lNoRecords = .T. *-------------------------------------------- *--- Disable the Delete, Edit buttons *--- (The parent method disables the grid) *-------------------------------------------- This.CListObj1.grdList.Refresh() This.CListObj1.grdList.Enabled = .F. This.cmdDelete.Enabled = .F. This.cmdEdit.Enabled = .F. * AW Disabled the following line in the hope that * this action will stop interference with keypress event * of host form. * This.cmdAdd.SetFocus() <--- AW commented this line ELSE *------------------------------------------- *--- Enable Delete, Edit buttons *--- (The parent method enables the grid) *------------------------------------------- * AW: Not really. There is no dodefault() anywhere in this method! * Added by AW: This.CListObj1.grdList.Refresh() This.CListObj1.grdList.Enabled = .T. This.cmdDelete.Enabled = .T. This.cmdEdit.Enabled = .T. ENDIFWhat I don't really understand is why the This.cmdAdd.SetFocus that I commented would interfere with the focus set by vfp. I went MMad looking for this one. I was typing on a control on the form so I would guess the focus was there. Somehow, however, when I hit