Path: utzoo!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!newstop!texsun!letni!rwsys!spudge!johnm From: johnm@spudge.UUCP (John Munsch) Newsgroups: comp.windows.ms.programmer Subject: Re: What do I do with stale window handles? (GetDesktopWindow() ) Keywords: Handles, Stale, Release, Destroy Message-ID: <28222@spudge.UUCP> Date: 8 Mar 91 14:53:23 GMT References: <1991Mar6.215823.3216@ssd.kodak.com> Reply-To: johnm@spudge.UUCP (John Munsch) Distribution: na Organization: Friends of Guru Bob Lines: 13 In article <1991Mar6.215823.3216@ssd.kodak.com> thomas@ssd.kodak.com (Thomas B. Kinsman (37681)) writes: > hwndDisplay = GetDesktopWindow(); > MessageBox(hwndDisplay, > (LPSTR) "Something went horribly wrong", > (LPSTR) "on a call to : Process(foo, bar)", MB_OK); We had mysterious crashes when we did what you are doing now. I have no idea why (Windows works in mysterious ways), but I do have a suggestion for a fix. Try MessageBox(NULL, ...) instead and I don't believe you'll have any more problems. John Munsch "Go buy some more Mac Classics, Apple has lawyers to pay."