Hi All,
am trying to catch the portal user id from a WD application. This is the piece of code I have written:
IWDClientUser wdUser = WDClientUser.getCurrentUser();
IUser user = wdUser.getSAPUser();
msgMgr.reportSuccess("wdUser = "wdUser" User = "+user); //Showing user = null here and not going into the loop
if (user != null){
IUserAccount[] acct = user.getUserAccounts();
if(acct[0] != null){
String strUserId = acct[0].getLogonUid();
msgMgr.reportSuccess("wdUser = "wdUser" User = "user" userId="+strUserId);
portalUser = strUserId;
}
}
I have added the securityapi.jar in build path. But I am not sure why the getSAPUser is always returning null. Please help...
regards,
Shubhadip