on 07-11-2006 7:08 AM
How can I identify the user of Enterprise Portal from my Web dynpro application.I anybody knows, please give the code with packages to be imported
hi Fahad,
try this snippet of code...
IWDClientUser wdUser = WDClientUser.getCurrentUser();
IUser user = wdUser.getSAPUser();
if (user != null)
{
IUserAccount[] acct = user.getUserAccounts();
if(acct[0] != null)
{
String strUserid = acct[0].getLogonUid();
wdContext.current"EP_info_node"Element().set"EP_info_element"(new String(strUserid));
}
}
you will need to add external jar for this.
Within the properties of the project, choose Java build path -> Libraries -> Add external jars ->
com.sap.securities -> lib -> com.sap.security.api.
hope this helps.
Regards,
Abhishek.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Fahad, did you try to type "portal user" in "Forum Search" input field and press "Go" in a top section of forum page? It gives me about 1K result items.
Regards, Maksim Rashchynski.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Use this code to get crrent user logged in:
IWDClientUser clientUser = WDClientUser.getCurrentUser();
IUser user = clientUser.getSAPUser();
and to get all user
IWDClientUser[] clientUserArray = WDClientUser.getClientUsers();
import com.sap.tc.webdynpro.services.sal.um.api.WDClientUser;
Regards,
Rajeev
Message was edited by: Rajeev Ranjan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
76 | |
9 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.