What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » [?] retrieve contact status

[?] retrieve contact status
Author: Message:
Cartox
Junior Member
**

Avatar
+1

Posts: 87
Reputation: 1
37 / Male / Flag
Joined: Jun 2004
O.P. [?] retrieve contact status
Hi,I think the folowing code is from the Open notifier Beta 0.5 from nx01rules.googlepages.com/
Is still use this code because it stil works (i know it isn't reliable :D)

I would like  the popup that's created to show the contact's status aswel.

so it would be somethin like "Contact (Away) has opened a conversation/session with you."

I've tried by adding Contact.Status after contact.name
but it didn't work.

do you have to make a list with the name's of the status somewhere?

code:
var PluginObj;

function OnEvent_Initialize(MessengerStart)
{
    if ( PluginObj == null )
    {
        OnEvent_Signin(Messenger.MyEmail);
    }
}

function OnEvent_Uninitialize(MessengerExit)
{
    PluginObj = null;
}

function SetWindowText(hWnd, sText)
{
    Interop.Call('user32', 'SetWindowTextW', hWnd, sText);
}

function OnWndOpenedEvent_EditTextChanged(PlusWnd,ControlId)
{
    if ( PlusWnd.GetControlText(ControlId) != "" )
    {
        var Contacts = Messenger.MyContacts;
        var Contact = Contacts.GetContact(PlusWnd.GetControlText(ControlId));
        if ( Contact == null )
        {
            MsgPlus.DisplayToast("Window Opened", PlusWnd.GetControlText(ControlId) + " has opened a conversation with you.", "", "ToastCallback", PlusWnd.GetControlText(ControlId));
        }
        else
        {
            MsgPlus.DisplayToast("Window Opened", Contact.Name + " has opened a conversation with you.", "", "ToastCallback", Contact.Email);
        }
        PlusWnd.SetControlText(ControlId, "");
    }
}

function ToastCallback(Param)
{
    Messenger.OpenChat(Param);
}

function LoadPlugin_VB(ProgId, CurrentEmail, OpenTextControlhWnd)
{
    PluginObj = new ActiveXObject(ProgId);
    if(PluginObj)
    {
        if(PluginObj.Initialize(8, CurrentEmail + "|" + OpenTextControlhWnd, undefined) == false)
        {
            MsgPlus.DisplayToast("Open Notifier", "Notifier was unable to load for an unknown reason");
        }
    }
}

function OnEvent_Signin(Email)
{
    var pOpenWindow = MsgPlus.CreateWnd("Opened.xml","WndOpened",1);
    SetWindowText(pOpenWindow.Handle, Email + "MSGPLNOTIFOPEN");

    LoadPlugin_VB("MSNWON.WindowNotifier", Email, pOpenWindow.GetControlHandle("Edt1"), 0);
}

function OnEvent_Signout(Email)
{
    PluginObj = null;
}


This post was edited on 12-08-2006 at 12:43 PM by Cartox.
[Image: cartoxbanr.jpg]

The statement below is True.
The statement above is False.
12-08-2006 10:12 AM
Profile PM Web Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
[?] retrieve contact status - by Cartox on 12-08-2006 at 10:12 AM
RE: [?] retrieve contact status - by Felu on 12-08-2006 at 10:25 AM
RE: [?] retrieve contact status - by Cartox on 12-08-2006 at 10:39 AM
RE: [?] retrieve contact status - by Felu on 12-08-2006 at 10:45 AM
RE: [?] retrieve contact status - by Cartox on 12-08-2006 at 10:57 AM
RE: [?] retrieve contact status - by NanaFreak on 12-08-2006 at 10:58 AM
RE: [?] retrieve contact status - by Cartox on 12-08-2006 at 11:07 AM
RE: [?] retrieve contact status - by Felu on 12-08-2006 at 11:19 AM
RE: [?] retrieve contact status - by Cartox on 12-08-2006 at 11:23 AM
RE: [?] retrieve contact status - by Felu on 12-08-2006 at 11:42 AM
RE: [?] retrieve contact status - by Cartox on 12-08-2006 at 12:23 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