

SUB myFocus
   Showmessage "focus"
END SUB

CREATE Form AS QFORMEX
    Width = 500
    Height = 300
    OnGetFocus = myFocus

CREATE StringGrid AS QSTRINGGRID
    Left = 0
    Top = 0
    Width = Form.Clientwidth
    Height = Form.Clientheight
    ColCount = 2
    RowCount = 2
    GridHeight = StringGrid.RowCount * (StringGrid.DefaultRowHeight + StringGrid.GridLineWidth) + 5
    GridWidth = StringGrid.ColCount * (StringGrid.DefaultColWidth + StringGrid.GridLineWidth) + 5
END CREATE
END CREATE
 