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

Error in code!
Author: Message:
Flaming Rob
Junior Member
**

Avatar

Posts: 43
Reputation: 2
Joined: Dec 2006
O.P. Huh?  Error in code!
Why isn't this working?



i = 0;
    names = new Array();
    names[0] = "";
    names[1] = "";
        emails = new Array();
    emails[0] = "me@hotmail.com";
    emails[1] = "me2@hotmail.com";
   
    smile = new Array;
    smile[0]  = "(L)";
    smile[1]  = "(K)";
    smile[2]  = "(F)";
    smile[3]  = ":$";
    smile[4]  = "(a)";
    smile[5] = ":)";
    smile[6] = ":(";
    smile[7] = ":'(";
    smile[8] = ":|";
    smile[9] = "|-)";
    smile[10] = ":@";
    smile[11] = "(B)";
    smile[12] = "^o)";
    smile[13] = "(R)";
    smile[14] = "(S)";
    smile[15] = "(*)";
    smile[16] = ":-#";
    smile[17] = "8o|";
    smile[18] = "(H)";
    smile[19] = "(T)";
    smile[20] = "(I)";
    smile[21] = "({)";
    smile[22] = "(})";
    smile[23] = ":P";
    smile[24] = "+o(";
    smile[25] = "(M)";
    smile[26] = "(@)";
    smile[27] = "(&)";

function OnEvent_Initialize(MessengerStart)
{   
   
    MsgPlus.AddTimer(6000"Update");
   
}

function OnEvent_Uninitialize(MessengerExit)
{
}

function onEvent_Timer(timerID)
{
   
    if(timerID == "Update")
    {
   
        var i = Math.floor(Math.random()*smile.length);
       
        for(var a = 0; a < emails.length; a+)
        {

            if(Messenger.MyEmail == emails[a])
            {
       
                Messenger.MyPersonalMessage = smile[i] + " " + names[a] + smile[i];
       
                MsgPlus.AddTimer("Update", 6000);
           
            }   

        }   
   
    }
   
}
[Image: robsigfw2.png]
01-30-2007 07:14 AM
Profile E-Mail PM Find Quote Report
ddunk
Veteran Member
*****

Avatar

Posts: 1228
Reputation: 51
35 / Male / Flag
Joined: Mar 2004
RE: Error in code!
quote:
Originally posted by Flaming Rob
MsgPlus.AddTimer(6000"Update");
Missing a comma.

Anything else in the debugger?
01-30-2007 07:17 AM
Profile E-Mail PM Web Find Quote Report
Jimbo
Veteran Member
*****

Avatar

Posts: 1650
Reputation: 18
32 / Male / Flag
Joined: Jul 2006
RE: Error in code!
Try this:
code:
    i = 0;
    names = new Array();
    names[0] = "HeHe--Random smilies(changes automatically every 6 seconds)";
    names[1] = "HeHe--Random smilies(changes automatically every 6 seconds)";

    emails = new Array();
    emails[0] = "me@hotmail.com";
    emails[1] = "me2@hotmail.com";
   
    smile = new Array();
    smile[0]  = "(L)";
    smile[1]  = "(K)";
    smile[2]  = "(F)";
    smile[3]  = ":$";
    smile[4]  = "(a)";
    smile[5] = ":)";
    smile[6] = ":(";
    smile[7] = ":'(";
    smile[8] = ":|";
    smile[9] = "|-)";
    smile[10] = ":@";
    smile[11] = "(B)";
    smile[12] = "^o)";
    smile[13] = "(R)";
    smile[14] = "(S)";
    smile[15] = "(*)";
    smile[16] = ":-#";
    smile[17] = "8o|";
    smile[18] = "(H)";
    smile[19] = "(T)";
    smile[20] = "(I)";
    smile[21] = "({)";
    smile[22] = "(})";
    smile[23] = ":P";
    smile[24] = "+o(";
    smile[25] = "(M)";
    smile[26] = "(@)";
    smile[27] = "(&)";

function OnEvent_Initialize(MessengerStart)
{   
   
    MsgPlus.AddTimer("Update", 6000);
   
}

function OnEvent_Uninitialize(MessengerExit)
{
}

function onEvent_Timer(timerID)
{
   
    if(timerID == "Update")
    {
   
        var i = Math.floor(Math.random()*smile.length);
       
        for(var a = 0; a < emails.length; a++)
        {

            if(Messenger.MyEmail == emails[a])
            {
       
                Messenger.MyPersonalMessage = smile[i] + " " + names[a] + smile[i];
       
                MsgPlus.AddTimer("Update", 6000);
           
            }   

        }   
   
    }
   
}


This post was edited on 01-30-2007 at 07:21 AM by Jimbo.
01-30-2007 07:18 AM
Profile E-Mail PM Find Quote Report
Flaming Rob
Junior Member
**

Avatar

Posts: 43
Reputation: 2
Joined: Dec 2006
O.P. RE: Error in code!
Sorry but that still doesn't work
[Image: robsigfw2.png]
01-30-2007 07:20 AM
Profile E-Mail PM Find Quote Report
Jimbo
Veteran Member
*****

Avatar

Posts: 1650
Reputation: 18
32 / Male / Flag
Joined: Jul 2006
RE: Error in code!
Updated previous post:)
01-30-2007 07:21 AM
Profile E-Mail PM Find Quote Report
Flaming Rob
Junior Member
**

Avatar

Posts: 43
Reputation: 2
Joined: Dec 2006
O.P. RE: Error in code!
Ok
Yes it is working now.
thanks

This post was edited on 01-30-2007 at 07:23 AM by Flaming Rob.
[Image: robsigfw2.png]
01-30-2007 07:22 AM
Profile E-Mail PM 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