Reputation: 1998
I am trying to create unit from Delphi7 > Project > Import Type Library
from mqoa.tlb or mqoa.dll, both on WinXP and on Win2003, and even more on Win7x64 (both mqoa30.tlb and mqoa.tlb (or *.dll), which stands for MSMQ 4.0) - every time it fails with error "Element not found".
According to MSMQ releases, on Windows 2003 and Windows XP "MSMQ 3.0" is installed, but in my old project I have MSMQ_TLB.pas
generated from mqoa20.tlb ("C:\WINDOWS\system32\mqoa20.tlb"). I want to switch to MSMQ 3.0 Interfaces, but I cannot.
Any suggestions?
By the way, once upon a time I found on internet MSMQ Delphi Example, using MSMQ_TLB.pas generated, probably for MSMQ 3.0, here is snippet from *TLP.pas header:
// Type Lib: C:\WINDOWS\system32\MQOA.DLL (1)
// LIBID: {D7D6E071-DCCD-11D0-AA4B-0060970DEBAE}
// LCID: 0
// Helpfile:
// HelpString: Microsoft Message Queue 3.0 Object Library
// DepndLst:
// (1) v2.0 stdole, (C:\WINDOWS\system32\stdole2.tlb)
I do not know if I can use it reliable in my project, replacing old one *TLB.pas (file uploaded here, project here).
Please advice - I am in total confusion what and how to use.
Upvotes: 2
Views: 6588
Reputation: 1998
I succeed doing it by installing newer version of Delphi (in my case - Delphi 2007): Main menu > Component > Import Component > Import Type Library...
After this, generated file(s) MSMQ_TLB.PAS (and *.dcr) are usable for Delphi 7 too.
Upvotes: 2