cancel
Showing results for 
Search instead for 
Did you mean: 

Regd Accessing Custom UME Attribute

Former Member
0 Kudos

Hi Experts,

I am new to portal development. I have a requirement to access a custom ume attribute in my portal masthead.

I used the IUser,IUserContext, IPortalComponentContext and IPortalComponentProfile Interface for this but no joy. For whatever attribute I access it returns only null either it be standard or custom ume attribute.

To get an Custom UME attribute specific to a logged in user what is the method i should use ??

What is the simplest method by which I can get and the set this attribute in my portal masthead par file.

All suggestions are highly appreciated.

Note: I referred the Forum for similar threads and cannot find a one matching my requirement, either it goes as reading UME attribute in Webdypro or some thing else.

Regards

Anand Sekar

Accepted Solutions (1)

Accepted Solutions (1)

p330068
Active Contributor
0 Kudos

Hi Anand,

Please refer to below document might help for your requirement

[|]

[http://help.sap.com/javadocs/NW04S/SPS09/se/index.html|http://help.sap.com/javadocs/NW04S/SPS09/se/index.html]

Best Regards

Arun Jaiswal

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi All,

Got the required output

The code line to be used is

IUserMaint userMaint = (IUserMaint)userFact.getMutableUser(username.getUniqueID());

Thanks for all your support.

Regards

Anand Sekar

Former Member
0 Kudos

Hi Arun,

Thanks for your reply.

Now I am able to fetch my Custom attribute. Now I tried to set the attribute with a value.

The problem i face here is I am not able to get an instance of logged in user in my userMaint object.

The coding goes like this

IUserMaint userMaint = ???? ;

boolean a = userMaint.setAttribute("com.sap.security.core.usermanagement","xxx",yyyy);

How should i bring in the current user data in userMaint object so that I will set the attribute for the user.

Aniticipating your help at the earliest.

Thanks in Advance

Regards

Anand Sekar

All suggestions are highly appreciated!!