Alt-F4 takes less time than clicking out through a menu, plus you get the added bonus of really being able to punch those keys.
From a programming point of view, it is a distinct MESSAGE in the windows message que\API. Only HiTech can answer if all the ideal shutdown and cleanup of the app occurs if any type of non-menu driven Window Close\Exit event occurs.
The cleanest most reliable way will always be to use the
application interface options to close and exit an application.
See "Programming Windows" by Charles Petzold for THE definitive documentation on the windows API.
Slade