>I built a small system which runs well in the interactive mode. When I build a .exe, the .exe runs fine when I select the run after build option, but when I run the executable from Windows Explorer it blinks for an instant and quits. Has anyone else encountered this?
I would say almost everyone has encountered this.
You need a READ EVENTS for VFP to wait for input; the command invoked from your "File | Exit" command, or similar, should include CLEAR EVENTS.
If you do it correctly, the Command Window should not appear while you are working from within VFP.
READ EVENTS can be thought of as an "endless loop in a single command": VFP waits for user input (menu click, click on a button, etc.). When an event occurs, VFP processes it, and then continues waiting.
HTH,
Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)