What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » A few questions.

A few questions.
Author: Message:
CookieRevised
Elite Member
*****

Avatar

Posts: 15519
Reputation: 173
– / Male / Flag
Joined: Jul 2003
Status: Away
RE: A few questions.
Going a bit of topic with this I guess.... but

Maybe you actually don't need MnJul's method.

In scripts you can use timers. Let's assume these timers are created internally like any other timer in Windows (seems logical). If that is tru, then couldn't you try to find out the id of the timer as it is known by Windows?

1) Allocate a 1 byte datablock in memory (use to check false triggers later on) and set it to 0xFF.
2) Create a timer and set the interval to maximum (one day)
3) Find out the timer id like it is known by Windows (dunno how this would be done in a reliable way though)
4) Pass that timer id (from Windows) and the datablock address to the DLL

5) When the DLL needs to trigger an event, let it change the datablock's value to 0x0 and..
6) ..let it set the timer's interval to like 10ms (after checking if they still exist of course). Or maybe broadcast a WM_TIMER message to the appropiate hWnd. All depends on how Plus! does its timers.

7) When the timer triggers, the script must check the value of the datablock. If it is 0xFF the timer was falsly triggered (you need to have been signed in for one day for that to happen though). If it is 0x0, the timer was triggered by the DLL. => bingo!
8) In either case, reinitialize the timer and set the datablock again to 0xFF.

So, these are a lot of wild assumptions here (steps 3 and 6 are the problem steps). But might be worthwhile or at least interesting to look into it... then again, it can't be that easy, can't it? lol

-------

And if that fails (very very likely), and you still don't want to create a small dedicated subclassed Plus! window to listen to the DLL, you could use ChatWnd.SendMessage (with MnJul's method) I suppose... which would then trigger to appropiate script event.

-------

Then again, to get back "on topic"... If you're going to use an external DLL anyways, wouldn't it already be able to do whatever this "new feature" is suppose to be doing nativly without the need to call back to the script? Thus no need for anything other then initializing the dll, and call it with the appropiate objects and whatever other stuff you might need (even maybe using MnJul's method to pass the needed Plus! and Messenger objects in case you need them).

I obviously need to get some sleep I suppose :p

This post was edited on 05-04-2010 at 11:43 PM by CookieRevised.
.-= A 'frrrrrrrituurrr' for Wacky =-.
05-04-2010 11:27 PM
Profile PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
A few questions. - by Emblem on 05-02-2010 at 03:29 AM
RE: A few questions. - by Matti on 05-02-2010 at 08:33 AM
RE: A few questions. - by CookieRevised on 05-03-2010 at 11:00 AM
RE: RE: A few questions. - by Matti on 05-03-2010 at 04:02 PM
RE: A few questions. - by CookieRevised on 05-04-2010 at 05:05 PM
RE: A few questions. - by Matti on 05-04-2010 at 06:15 PM
RE: A few questions. - by CookieRevised on 05-04-2010 at 06:32 PM
RE: A few questions. - by Eljay on 05-04-2010 at 06:51 PM
RE: A few questions. - by CookieRevised on 05-04-2010 at 07:01 PM
RE: A few questions. - by Eljay on 05-04-2010 at 07:47 PM
RE: A few questions. - by CookieRevised on 05-04-2010 at 08:03 PM
RE: RE: A few questions. - by TheSteve on 05-05-2010 at 07:29 AM
RE: A few questions. - by Eljay on 05-04-2010 at 10:14 PM
RE: A few questions. - by CookieRevised on 05-04-2010 at 11:27 PM
RE: A few questions. - by Eljay on 05-05-2010 at 08:41 AM
RE: A few questions. - by Mnjul on 05-05-2010 at 08:50 AM
RE: A few questions. - by CookieRevised on 05-06-2010 at 01:04 AM
RE: A few questions. - by Mnjul on 05-06-2010 at 06:49 AM
RE: A few questions. - by Eljay on 05-06-2010 at 07:25 AM
RE: A few questions. - by Emblem on 05-17-2010 at 05:07 PM


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