OK- I've got the test sample converted to Borland C++ Builder, I can build it and attempt to install it. When I do, I first get a call to DLL_PROCESS_ATTACH followed by an immediate call to DLL_PROCESS_DETACH. Then I end up with the dreaded "Couldn't initialize" message. Doesn't seem to matter what call convention I use, although I've somewhat settled on __stdcall __declspec(dllexport) in order to get the pascal conventions in order. None of my other breakpoints get hit.
My guess is that the DLL header conventions are different in C++ and Pascal and when TB is trying to initialize the plugin it can't find the TBP_Initialize() function. Here's what's in my DLL header: +++++++++++++++++++ EXPORTED FUNCTIONS +++++++++++++++++++ Number of Exported Functions = 10 (decimal) Addr:004012A0 Ord: 1 (0001h) Name: TBP_Initialize((short,void)) Addr:004012B8 Ord: 2 (0002h) Name: TBP_Finalize((short,void)) Addr:004012D0 Ord: 3 (0003h) Name: TBP_GetName((short,char*,int)) Addr:00401360 Ord: 4 (0004h) Name: TBP_GetVersion((short,char*,int)) Addr:0040137C Ord: 5 (0005h) Name: TBP_GetStatus((short,void)) Addr:004013A0 Ord: 6 (0006h) Name: TBP_NeedConfig((short,void)) Addr:004013C4 Ord: 7 (0007h) Name: TBP_NeedCOM((short,void)) Addr:004013E8 Ord: 8 (0008h) Name: TBP_Setup((short,void)) Addr:0040140C Ord: 9 (0009h) Name: TBP_GetSpamScore((short,int,(int,int,char*,int)*,int)) Addr:004020F8 Ord: 10 (000Ah) Name: ___CPPdebugHook To me, the names look right - no leading underscore, etc. Can (A) someone confirm that this is correct and/or (B) can someone (Stefan?) post the TBtest.dpr sample made into a DLL with Delphi so that I can compare the PE headers, or (C) come up with any other ideas? -Mark Wieder Using The Bat! v1.61 on Windows 2000 5.0 Build 2195 Service Pack 2 -- ________________________________________________ Current version is 1.62 | "Using TBDEV" information: http://www.silverstones.com/thebat/TBUDLInfo.html