I wrote things about this problem in November 2004 and saw it isn’‘t fixed yet… so I’'m going for a second try…
It is impossible in 200B3 to kick an user, or change its Role (if you are owner or mod. of course!)…
in Room.as[/u] at line 410 change
ext.addItem(null, MUC.NO_ROLE, null, null, null, reason);[/i]
into
ext.addItem(null, MUC.NO_ROLE, occupantNick[/b], null, null, reason);[/i]
And you could do the same for setOccupantVoice function at line 428.
As I wanted to grant ppl to moderator, I tried more modifications, which are working well:
public function setOccupantVoice( occupantNick:String, newRole:String /b):Void
{
if( isActive() ) {
var tempIQ:IQ = new IQ( getRoomJID(), IQ.SET_TYPE, XMPPStanza.generateID(“voice_”) );
var ext:MUCAdminExtension = new MUCAdminExtension(tempIQ.getNode());
ext.addItem(null, newRole[/b],occupantNick);
tempIQ.addExtension(ext);
myConnection.send( tempIQ );
}
}
/i
I can change a nickname Role by using one of these examples:[i]
chatRoom.setOccupantVoice(selectedNickname,MUC.MODERATOR_ROLE);
chatRoom.setOccupantVoice(selectedNickname,MUC.VISITOR_ROLE);
chatRoom.setOccupantVoice(selectedNickname,MUC.PARTICIPANT_ROLE);[/i]