KeyPress Method
Object:frmreports.lstReport
Expand/Collapse source code of procedure lstReport.KeyPress Source Code
LPARAMETERS nKeyCode, nShiftAltCtrl

*-- We want to provide the user with a visual clue that the
*-- Run command button is the default button.(By setting it's
*-- Default property.  However, if we don't trap for the
*-- Enter key being pressed, the DblClick() method will be
*-- called implicitly, and so will the click event for the
*-- Run command button. This results in the report being run
*-- twice.

IF nKeyCode = 13
  NODEFAULT
  this.DblClick()
ENDIF