user687022
user687022

Reputation: 169

smack Message not comming when my message Type is Message.Type.groupchat

I am sending a message to jabber as

Message msgMultipleChat = new Message(to);//,Message.Type.chat);

msgMultipleChat.setBody(inputChatText);
msgMultipleChat.setType(Message.Type.groupchat);
msgMultipleChat.setFileType("text");
msgMultipleChat.setFile("");
//msgMultipleChat.setFriendName(userIds);
msgMultipleChat.setFrom(userIds);
msgMultipleChat.setGroupId(mGroupId);
if(BizproConnection.mXMPPConnection.getHost()!=null ) {
    BizproConnection.mXMPPConnection.sendPacket(msgMultipleChat);
}

I am not able to recieve it but when the Message type is chat i am able to recieve it why is it so

Upvotes: 0

Views: 549

Answers (1)

Flow
Flow

Reputation: 24053

If the value of to is not the JID of a MUC then the message is invalid because Type.Groupchat is only valid when communicating with a MUC instance (XEP-0045).

Upvotes: 2

Related Questions