Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.

Always get [object UserDescriptor] when try to get user

Avatar

Level 1

Hey there,

hope anyone can help. I'm trying to get the participants usernames in my chatroom but all i get is [object UserDescriptor] for each user.

My code is:

<rtc:ConnectSessionContainer

initialize="inicount();" roomURL="https://collaboration.adobelivecycle.com/bsender/myfirstroom" id="cSession" authenticator="{auth}" width="100%" height="100%" autoLogin="false">

<mx:Panel

width="620" height="412" title="BloodChat" layout="absolute" cornerRadius="15" verticalCenter="15" horizontalCenter="-0">

<coreUI:EmoticonTextArea width="415" height="305" x="0" id="chat_mesg_area" borderColor="#DEDBDB" y="0"/>

<s:Button label="Button" click="{Alert.show(cSession.userManager.userCollection[0].toString())}"/> //here i try to get the name

...

I also have a list and the cSession as dataProvider. But this also only returns  [object UserDescriptor] for each list item. (although it shows the usernames in itself)

2 Replies

Avatar

Employee

Did you look at the documentation for UserDescriptor ? I am pretty sure there is a displayName property you can use.

Sent from my iPhone

Avatar

Level 1

yap. already found. it's just the simple object array

which contains the displayname, userid, ...