powered by Jive Software

Sending message to a MSN user using Smack API

Hi,

I am trying to send a simple message to a msn user (the user is in the contact list ). The MSN user was added as contact from spark IM Client.

From Spark Client I can send a message, and I want to be able to send a message via the smack API too.

the simple client is

XMPPConnection connection = new XMPPConnection(“10.90.2.22”); // Where my openfire is installed

connection.connect();

connection.login(“tezhotels”, “XXXXX”);

      Chat chat = connection.getChatManager().createChat("gunay@teztechnology.com@msn.teztour.com.tr", new MessageListener() {

public void processMessage(Chat chat, Message message) {

System.out.println("Received message: " + message);

}

});

chat.sendMessage(“Howdy!”);

but smack is giving me error , at JID .

When I debug Spark client I see 2 messages

I tried to setup

Chat chat = connection.getChatManager().createChat(“gunay\40teztechnology.com@msn.teztour.com.tr”, …

but got the same error.

Any Help ??