What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » Help me with a Basic.. and easy.. script

Pages: (2): « First « 1 [ 2 ] Last »
Help me with a Basic.. and easy.. script
Author: Message:
Jesus
Scripting Contest Winner
****

Avatar
Koffie, my cat ;)

Posts: 623
Reputation: 15
38 / Male / Flag
Joined: Jul 2005
RE: Help me with a Basic.. and easy.. script
lol sorry I misplaced the return "";
after fixing the code and actually testing it I found out that this method doesn't work like expected.
To actually annoy your contact with lots of toasts and sounds I suggest you take a look at MsgPlus Timers in the scripting documentation and fiddle around a bit with them.


quote:
Originally posted by Matty
code:
function OnEvent_ChatWndSendMessage(oChatWnd, nMessage){
    var aContacts = new Array();
    if (nMessage === '/cBlock'){
        for (var e = new Enumerator(oChatWnd.Contacts); !e.atEnd(); e.moveNext()){
            aContacts[aContacts.length] = e.item().Email;   //Don't use .Email, you need the contact object.
        }
        for (var j=0; j < 5; j++){
            for (var i in aContacts){
                aContacts[i].Blocked = !aContacts[i].Blocked; //Doesn't work if called too quick after each other.
            }
        }
        return '';
    }
}

function OnGetScriptCommands(){
    return '<Command><Name>cBlock</Name></Command></ScriptCommands>'; //<ScriptCommands> is missing
}

Maybe they are already blocked!
Won't work, see the comments...

This post was edited on 03-20-2007 at 05:50 PM by Jesus.
Man is least himself when he is in his own person. Give him a mask and he will tell you the truth. (Oscar Wilde)
03-20-2007 05:41 PM
Profile PM Find Quote Report
Joined_
New Member
*


Posts: 6
Joined: Mar 2007
O.P. RE: Help me with a Basic.. and easy.. script
Messenger don't seems to know this command!!!

.bmp File Attachment: ad.bmp (89.58 KB)
This file has been downloaded 117 time(s).
03-20-2007 05:47 PM
Profile E-Mail PM Find Quote Report
matty
Scripting Guru
*****


Posts: 8336
Reputation: 109
39 / Male / Flag
Joined: Dec 2002
Status: Away
RE: Help me with a Basic.. and easy.. script
Code should work now however as the second comment says if .Blocked is called too early it may not work. Learn to use Timers.
03-20-2007 05:54 PM
Profile E-Mail PM Find Quote Report
Pages: (2): « First « 1 [ 2 ] Last »
« 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