I do:
var mi = new MessageItem("complexObjectNode", myUserMsg);
mi.associatedUserID = _cSession.userManager.myUserID;
mi.recipientID = budyUserID;
collectionNode.publishItem(mi);
and get:
Error: MessageManager.publishItem : cannot publish private messages on a node unless it is configured to allowPrivateMessages
at com.adobe.rtc.messaging.manager::MessageManager/http://www.adobe.com/2006/connect/cocomo/messaging/internal::publishItem()
at com.adobe.rtc.sharedModel::CollectionNode/publishItem()
at SimpleChat/sendMsg()
at SimpleChat/onItemReceive()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at com.adobe.rtc.sharedModel::CollectionNode/http://www.adobe.com/2006/connect/cocomo/messaging/internal::receiveItem()
at com.adobe.rtc.messaging.manager::MessageManager/http://www.adobe.com/2006/connect/cocomo/messaging/internal::receiveItem()
at com.adobe.rtc.session.managers::SessionManagerBase/receiveItem()
So i did this:
var nodeConfiguration:NodeConfiguration = new NodeConfiguration();
nodeConfiguration.allowPrivateMessages = true;
collectionNode.createNode("complexObjectNode", nodeConfiguration);
but I still get the error.