home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / os / os2 / programm / 7280 < prev    next >
Encoding:
Text File  |  1993-01-03  |  1.4 KB  |  36 lines

  1. Newsgroups: comp.os.os2.programmer
  2. Path: sparky!uunet!think.com!spool.mu.edu!umn.edu!csus.edu!netcom.com!daveb
  3. From: daveb@netcom.com (Dave Briccetti)
  4. Subject: Re: Dialogs + Threads = Problems. Help!
  5. Message-ID: <1993Jan3.054918.1861@netcom.com>
  6. Organization: Dave Briccetti & Assoc., OS/2 Consulting
  7. References: <92366.110046U37127@uicvm.uic.edu>
  8. Date: Sun, 3 Jan 1993 05:49:18 GMT
  9. Lines: 25
  10.  
  11. U37127@uicvm.uic.edu () writes:
  12. : I have received E-mail (rob@cc.gatech.edu) saying that the thread
  13. : issuing the WinSendMsg must have a msg Q as well; I also received
  14. : another answer saying that a thread *cannot* use WinSendMsg
  15. : to a window belonging to another thread (lhoang@orion.uci.edu) and
  16. : that this behaviour is documented.  Apparently IBM recommends
  17. : WinPostMsg.  Perhaps to maintain serialization via the msg Q
  18. : as opposed to WinSendMsg which is a direct call to the function?
  19. : Is there a definitve doc anywhere on this subject?  My interim kludge has been
  20. : to use WinPostMsg, with an app defined msg, and block until the receiver
  21. : processes the msg and shoves the result into a shared data structure.
  22.  
  23. The notes in the PM Reference make it quite clear that WinSendMsg to a
  24. window belonging to another thread IS allowed.  The message is sent 
  25. synchronously and the thread switching is automatic.
  26.  
  27. I've done it myself for years.
  28.  
  29. -- 
  30.  
  31. Dave Briccetti, Owner, Dave Briccetti & Associates
  32. OS/2 Developer/Consultant
  33. P.O. Box 1713
  34. Lafayette, CA  94549-7013
  35.