Board index » delphi » Useful Win API function -- SetErrorMode
sco...@cencom.net (Scott Hembrough)
![]() Delphi Developer |
Mon, 26 Jan 1998 03:00:00 GMT
Useful Win API function -- SetErrorMode
Hi everyone!
I am new to the world of Delphi and the Windows API, so I was pretty e{*word*277}d BACKGROUND: I am writing an application that reports various statistics about ORIGINAL PROBLEM: Whenever I tried to report the size of a floppy or cd-rom INITIAL REACTION: Confusion and frustration... until I found the SetErrorMode SOLUTION: Call the SetErrorMode Windows API function (available in the To quote the Windows API Help file directly, "The SetErrorMode function To rephrase this in plain english, this function allows you take control of SetErrorMode(SEM_FAILCRITICALERRORS); The SEM_FAILCRITICALERRORS function basically tells Windows not to display the As a result, I am now able to proceed normally as I loop through all of the CONCLUSION: I can now sleep at night knowing that this is no longer a problem Hope this helps somebody!!! Scott |