You say there is no way to do this in VFP. What is wrong with this previous suggestion of creating a commandbutton class and setting the procedures within?
myform = createObject('FORM')
myform.visible = .t.
myform.AddObject('exitbutton','myButton')
myform.exitbutton.visible = .t.
DEFINE CLASS myButton as COMMANDBUTTON
PROCEDURE Click
thisform.release
CLEAR EVENTS
ENDPROC
caption = 'Exit'
ENDDEFINE
Paul A. Busbey
I.S. Department
Sparagowski & Associates
Paul A. Busbey
Victoria Insurance