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

External scripts
Author: Message:
ArkaneArkade
Full Member
***

Avatar
The One and Only

Posts: 193
Reputation: 5
38 / Male / Flag
Joined: Mar 2007
O.P. External scripts
Hey guys,

I'm having problems with one of my scripts not reverting back to images well enough, so I've decided to just forgo the method I was using and call an external script for it instead.  I know (or at least think) theres no built in method to do this, but the script I wanna run has message commands, so I'm gonna try it that way.

Problem is, I can't quite find out what it is I'm doing, and was hoping someone may be able to give a small pointer.

Basically, I was thinking of checking the chatwnd count, and if its 0, open a chat, send the message, tehn close the chat - although I cant find how to close a window.

Alternately, I read once that plus can open chats to yourself?  is this actually possible, because I seem to be failing at it.  I'm considering perhaps that it may be better to just open a chat to yourself every time (I dont expect this function to be called often) and send the command, but I'm unsure of how this may affect the system (I'm currently on a old, dodgy PC after killing my good ones drive).

Any pointers?  cheers all
[Image: adsig.jpg]
01-07-2009 07:50 PM
Profile E-Mail PM Web Find Quote Report
matty
Scripting Guru
*****


Posts: 8336
Reputation: 109
39 / Male / Flag
Joined: Dec 2002
Status: Away
RE: External scripts
To close the Chat Window
Javascript code:
var pChatWnd = Messenger.OpenChat('johndoe@hotmail.com');
pChatWnd.SendMessage('this is a message');
Interop.Call('user32', 'SendMessageW', pChatWnd.Handle, 0x10 /* WM_CLOSE */, 0, 0);

01-07-2009 08:30 PM
Profile E-Mail PM Find Quote Report
ArkaneArkade
Full Member
***

Avatar
The One and Only

Posts: 193
Reputation: 5
38 / Male / Flag
Joined: Mar 2007
O.P. RE: External scripts
Cheers matty.  That works perfectly.  Only problem is if I send a message to an already open window... but I think I have it sending to one that should never be open, so no probs.
Thanks man
[Image: adsig.jpg]
01-08-2009 04:23 AM
Profile E-Mail 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