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

Scripting Bug
Author: Message:
a0369
Junior Member
**

Avatar

Posts: 16
35 / Male / Flag
Joined: Oct 2004
O.P. Scripting Bug
I think I found a bug while I was scripting in Messenger Plus. A part of my script is supposed to check my status and if my status is away any conversation message that is received after that is supposed to get an auto response, problem is that it won't send the message. I check the debugger and it says "ChatWnd" is undefined. Any ideas?
01-02-2007 05:09 AM
Profile PM Web Find Quote Report
NanaFreak
Scripting Contest Winner
*****


Posts: 1476
Reputation: 53
32 / Male / Flag
Joined: Jul 2006
RE: Scripting Bug
would you be able to post your code so that we can have a look at where you might be going wrong?
01-02-2007 05:20 AM
Profile PM Find Quote Report
a0369
Junior Member
**

Avatar

Posts: 16
35 / Male / Flag
Joined: Oct 2004
O.P. RE: Scripting Bug
here's where the error occures

code:
function OnEvent_ChatWndReceiveMessage(chatwin,origin,txt_msg,kind)
{
        var msg_back="";
        switch (Messenger.MyStatus)
        {
            case '6': msg_back="Be aware that I haven't been on my computer for longer than 10 minutes and may not respond!";
            break;
            case '7': msg_back="I'm away and probably won't respond!";
            break;
            default : msg_back="";
            break;
        }
        if (response_text=="")
        {
            if (msg_back!="")
            {
                ChatWnd.SendMessage(msg_back);
            }
        }
        else
        {
            ChatWnd.SendMessage(response_text);
        }
}

01-02-2007 05:24 AM
Profile PM Web Find Quote Report
NanaFreak
Scripting Contest Winner
*****


Posts: 1476
Reputation: 53
32 / Male / Flag
Joined: Jul 2006
RE: Scripting Bug
ok the bug is that ChatWnd.SendMessage.... the ChatWnd part has to be the same as the variable for the function ;)

so it would be chatwin.SendMessage("Message");
01-02-2007 05:26 AM
Profile PM Find Quote Report
a0369
Junior Member
**

Avatar

Posts: 16
35 / Male / Flag
Joined: Oct 2004
O.P. RE: Scripting Bug
ok, I made the change and it worked, I thought that was a global object
01-02-2007 05:27 AM
Profile PM Web Find Quote Report
Chestah
Veteran Member
*****

Avatar

Posts: 1658
Reputation: 34
35 / Male / –
Joined: Jun 2004
RE: Scripting Bug
quote:
Originally posted by a0369
ok, I made the change and it worked, I thought that was a global object

nope, because you could have many chat windows open at once. It would suck if you only manipulate the chat window that sent the message in each plus! function.
Segosa is newb.
01-02-2007 08:49 AM
Profile E-Mail PM Web Find Quote Report
roflmao456
Skinning Contest Winner
****

Avatar

Posts: 955
Reputation: 24
29 / Male / Flag
Joined: Nov 2006
Status: Away
RE: Scripting Bug
maybe you can add in the message to send to all chat windows

"/all *message here*" :D

This post was edited on 01-02-2007 at 11:59 PM by roflmao456.
[quote]
Ultimatess6
: What a noob mod
01-02-2007 11:57 PM
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