Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!samsung!uunet!sjsca4!poffen From: poffen@sj.ate.slb.com (Russell Poffenberger) Newsgroups: comp.windows.ms Subject: Re: MessageBox problem Message-ID: <1990Sep20.174228.613@sj.ate.slb.com> Date: 20 Sep 90 17:42:28 GMT References: <1990Sep9.224303.10981@bdmrrr.bdm.com> <1990Sep11.074217.18928@ciba-geigy.ch> <1990Sep12.043315.10404@Neon.Stanford.EDU> Reply-To: poffen@sj.ate.slb.com (Russell Poffenberger) Organization: Schlumberger Technologies, San Jose, CA. Lines: 32 In article <1990Sep12.043315.10404@Neon.Stanford.EDU> hoang@Neon.Stanford.EDU (My Khanh Hoang) writes: > > I am the original poster of the problem. I would like to thank all who > attempted to help me solve the problem. Regrettably, none of the > suggestions help. > The casting is taken care of by #include . > There was no missing MakeProcInstance or exported name. > I even tried to LockData() and made the data segment fixed as Bob > Goodearl suggested. > I am still waiting for more help! > The problem is MessageBox(hDlg, "abc", "xyz", MB_OK) does not display > text strings as expected (strings are garbled up). > The call is made within a dialog box window procedure. There is no > global or local allocation of memory. I did try to increase the stack > size in .def file but this did not help. The machine I use is a PS2 > 80. Windows and SDK are 3.0. > By the way, a similar call made outside the dialog box window procedure > works MessageBox(hWnd, "abc", "xyz", MB_OK) where hWnd is parent of > hDlg. I have found that MessageBox doesn't work properly in all cases. In attempting to write a dll (Screen Peace saver extension), I called MessageBox to try and debug a problem, this failed and caused the system to hang. Running CVW spit out a continuous ream of messages indicating that there were no more Device Contexts available. It seemed to get stuck forever in a loop at that point. Russ Poffenberger DOMAIN: poffen@sj.ate.slb.com Schlumberger Technologies UUCP: {uunet,decwrl,amdahl}!sjsca4!poffen 1601 Technology Drive CIS: 72401,276 San Jose, Ca. 95110 (408)437-5254