Skip to Content
0
Former Member
May 28, 2008 at 02:57 PM

Problem in getting portal user: DC Project

17 Views

Hi,

I am having a problem in getting the portal user in the DC project. I saw lot of posting, but all posting are for WebDynpro projects. I am using the below code in a java file(eg: Util.java)

IWDClientUser wdUser = WDClientUser.getCurrentUser();

IUser user = wdUser.getSAPUser();

String str = user.getUniqueName();

I added the above file in the External Library DC and i brought it in Library DC.Finally i added this as a Used DCs in my main WebDynpro DC project.Also i added com.sap.security.api.jar as a Used DCs and i authenticated the application.I am not getting any error when i Build, Deploy and Run the application.

But the IUser always returns null.

I request someone to help me to solve this issue.

Thanks,

Ramesh