What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » Plug-Ins » a question about C++ plugins.

a question about C++ plugins.
Author: Message:
Ash_
Senior Member
****

Avatar

Posts: 638
Reputation: 31
35 / Male / –
Joined: Aug 2004
O.P. a question about C++ plugins.
do C++ plugins require any Strings entered into the Registry, or any other place that can determine it is the plugin?


if not how can Patchou tell that test1.dll is the plugin and test2.dll is a DLL require by test1.dll and is not a plugin.

thanks in advance?
[Image: jeansiger5.jpg]
09-12-2005 10:43 PM
Profile PM Find Quote Report
Mnjul
forum super mod
******

Avatar
plz wub me

Posts: 5396
Reputation: 58
– / Other / Flag
Joined: Nov 2002
Status: Away
RE: a question about C++ plugins.
No it does not require a string.

To answer your "if Plus! can determine it" question, go to your...
HKCU\Software\Patchou\MsgPlus2\(YourEmail)\Preferences\Plugins and you'll see that all your dlls in Plugins directory are actually "read" by Plus!...My guess is Plus! will first try to load the DLL (and DllMain will be called or something), and if it sucessfully returns true, Plus! attempts to call Initialize, and so forth. If everything's fine, Plus! will recognize it as a Messenger Plus! plug-in. :)

Smart Patchou, isn't he? :P

This post was edited on 09-13-2005 at 01:57 AM by Mnjul.
09-13-2005 01:54 AM
Profile PM Web Find Quote Report
Ash_
Senior Member
****

Avatar

Posts: 638
Reputation: 31
35 / Male / –
Joined: Aug 2004
O.P. RE: a question about C++ plugins.
quote:
Originally posted by Mnjul
No it does not require a string.

To answer your "if Plus! can determine it" question, go to your...
HKCU\Software\Patchou\MsgPlus2\(YourEmail)\Preferences\Plugins and you'll see that all your dlls in Plugins directory are actually "read" by Plus!...My guess is Plus! will first try to load the DLL (and DllMain will be called or something), and if it sucessfully returns true, Plus! attempts to call Initialize, and so forth. If everything's fine, Plus! will recognize it as a Messenger Plus! plug-in. :)

Smart Patchou, isn't he? :P

lol yeh smart. but that means my program will take alot longer to code *sigh* thanks for your help though Mnjul :)
[Image: jeansiger5.jpg]
09-13-2005 05:48 AM
Profile PM Find Quote Report
segosa
Community's Choice
*****


Posts: 1407
Reputation: 92
Joined: Feb 2003
RE: RE: a question about C++ plugins.
quote:
Originally posted by Mnjul
No it does not require a string.

To answer your "if Plus! can determine it" question, go to your...
HKCU\Software\Patchou\MsgPlus2\(YourEmail)\Preferences\Plugins and you'll see that all your dlls in Plugins directory are actually "read" by Plus!...My guess is Plus! will first try to load the DLL (and DllMain will be called or something), and if it sucessfully returns true, Plus! attempts to call Initialize, and so forth. If everything's fine, Plus! will recognize it as a Messenger Plus! plug-in. :)

Smart Patchou, isn't he? :P


I think he checks if Initialize() has been exported, and if so, calls it, and depending on the return value adds the plugin to the registry.
The previous sentence is false. The following sentence is true.
09-13-2005 06:11 AM
Profile PM Find Quote Report
RaceProUK
Elite Member
*****

Avatar

Posts: 6073
Reputation: 57
39 / Male / Flag
Joined: Oct 2003
RE: a question about C++ plugins.
Actually, all DLLs are added to the Registry, but those that explort Initialize() are recorded as such, and Plus! doesn't attempt to load those that don't next time. And it's not just exporting Initialize(), it's exporting 'extern "C" __declspec(dllexport) BOOL __stdcall Initialize(DWORD nVersion, const char *sUserEmail, IDispatch *iMessengerObj)'.

Function signature is very important ;)
[Image: spartaafk.png]
09-13-2005 09:59 AM
Profile PM Web Find Quote Report
« Next Oldest Return to Top Next Newest »


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On