- Mark as New
- Follow
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report
Yes, the method takes two parameters, but the first is the reference to the group object itself; you only need to provide the recipient list parameter, as declared in the method signature.
You could add recipients to a list per code like so:
var groupId = 499360; // the group id
var recipientIds = [5585, 53239]; // recipient ids as array
var collection = <rcpGrpRel-collection xtkschema="nms:rcpGrpRel"/>;
for each (var recipientId in recipientIds) {
var collectionItem = <rcpGrpRel xtkschema="nms:rcpGrpRel" _key="@group-id,@recipient-id" group-id={groupId} recipient-id={recipientId}/>;
collection.appendChild(collectionItem);
}
xtk.session.WriteCollection(collection);