Solved

Send Message via MSN Messenger

Posted on 2011-02-13
4
966 Views
Last Modified: 2013-12-14
Hi,
I want to send message and file from MSN Messenger to MSN Messenger with C#.
When MSN Messenger opened. I want to control it. Change nickname, send message to added contacts etc.
How can I do it?

Sorry for my bad English.
Thanks.
0
Comment
Question by:fancyfanta
  • 2
  • 2
4 Comments
 
LVL 3

Expert Comment

by:chandra_darbha
ID: 34885791
There seems to be no straightforward way for doing it. I too tried with Office Communicator 2005 sometime back but in vain. The below links might help you in making a C# app independent of the Messenger -

http://www.codeproject.com/KB/cs/enhancedmessenger.aspx
http://www.codeproject.com/KB/cs/Connect_To_MSN_Messenger.aspx
http://msdn.microsoft.com/en-us/library/ms630960(VS.85).aspx
http://social.msdn.microsoft.com/Forums/en/wlmessengerdev/thread/ecea4566-2cfe-4285-b9be-27867f4d0fd4
0
 

Author Comment

by:fancyfanta
ID: 34890148
I researched all those links, whole google....
I think, I must use MSN Messenger DLL files.
But which?
0
 
LVL 3

Accepted Solution

by:
chandra_darbha earned 500 total points
ID: 34894234
I tried to write a small app yesterday. Here is what I wrote and it worked. But, I had Office Communicator 2005 and a similar approach should work with MSN Messenger.

 
CommunicatorAPI.MessengerClass m = new CommunicatorAPI.MessengerClass();

CommunicatorAPI.IMessengerContactAdvanced contact = m.GetContact("user@domain.com", string.Empty) as CommunicatorAPI.IMessengerContactAdvanced;

this.Visible = false;
CommunicatorAPI.IMessengerConversationWndAdvanced imWindow = m.InstantMessage(contact) as CommunicatorAPI.IMessengerConversationWndAdvanced;            

imWindow.Show();

SendKeys.Send("Hello, this is an autobot");
SendKeys.Send("{ENTER}");

Open in new window


Below are the references I added.

 References Screenshot
Hope this helps.

Thanks,
Chandra
0
 

Author Closing Comment

by:fancyfanta
ID: 34972547
This is not true method but, I follow this method then it worked.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
The viewer will learn how to use and create keystrokes in Netbeans IDE 8.0 for Windows.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now