| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | Secondary thread / PMERR_NOQUEUE (0 |
Hello all!
Another problem I come across writing code for a secondary thread is that
after the followning instructions WinGetLastError reports errorno 0x1036.
The code might look a bit funny to you C people, but that is because it is pascal.
// thread initialisation, creating an anchorblock and message queue
AnchorBlock:=WinInitialize(0);
MessageQ := WinCreateMsgQueue(AnchorBlock,QSize);
// Then I register the class, having the anchorblock in AHAB, the name of
the object in
// WinName, the procedure is in ObjectWinProc
if not WinRegisterClass(AHAB,WinName,{at}ObjectWinProc,0,Sizeof(pointer)) then ;
// check whether there is a class registered with the name contained in WinName
if not WinQueryClassInfo(AHAB,WinName,ClsInfo) then
WinMessageBox(HWND_Desktop,HWND_Desktop,'Could not register','error',0,mb_ok);
// now create the object-window for the secondary-thread...
HWindow := WinCreateWindow(HWND_Object,WinName,'',
0,0,0,0,0,HWND_OBJECT,HWND_TOP,
0,NIL,NIL);
after trying to create the object-window WinGetLastError reports the PM
error that there is no message queue, though I am sure I had one created
through the call to WinCreateMsgQueue
What could cause this PM-confusion?
Bye, Erik!
[TeamOS/2 NL]
preferred personal reactions through e-mail
[internet: ErikH{at}hcc-gron.idn.nl]
--- FleetStreet 1.14 NR
* Origin: ORIGINal messages, I like them (2:500/19.1929)SEEN-BY: 50/99 270/101 620/243 711/401 409 410 413 430 808 809 934 955 SEEN-BY: 712/407 515 517 628 713/888 800/1 7877/2809 @PATH: 500/19 9 28/777 2/777 396/1 270/101 712/515 711/808 809 934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.