Expand my Community achievements bar.

Radically easy to access on brand approved content for distribution and omnichannel performant delivery. AEM Assets Content Hub and Dynamic Media with OpenAPI capabilities is now GA.

Get user groups and username

Avatar

Level 2

I work with ActionScript 3 and LiveCycle workspace 8.2.  I need to read the user name (display name) for a user which has logged in to workspace and additionally I want to retrieve the users group names.

With help of the following code I am able to get a user object (class lc.domain.user) and display the user information, but I'm not able to read the user name and groups.

                var session : SessionMap = SessionMap( Application.application.session );
                var sessionManager : ISessionManager = ISessionManager( session.getObject( "lc.core.ISessionManager" ) );

                var user:User = sessionManager.authenticatedUser;

                Alert.show( ObjectUtil.toString( user) );

According to the API the lc.domain.user class has a public property displayName and groups, but the Compiler does not recognize these properties and there are no getter or setter methods.

Any ideas?

1 Reply

Avatar

Level 10

I am not sure about ActionScript APIs.

If you could consider an alternet way, you could try this.

Create a short lived process with a LDAP search component. Search the user info in LDAP and return the memberOf attribute.

This short-lived process can be invoked from PDF/Flex form through SOAP.

Nith