on 12-29-2005 6:31 PM
I need to develop a WEBDYNPRO program that
checks the existence and eventually reads the following data from any userID allowed to enter the portal: Name, LastName and Profile.
thanks, I cannot recover the user with GETSAPUSER why in that moment the amministatore is connected. The administrator must insert USERID of a customer and control of the existence. For Example the administrator inserts USERID "TOMMY" and presses push-button "CHECK" of the WebDynpro. Therefore the message will be visualized: Present customer or not present Customer and other information of the customer!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Mario,
1. User enters the Portal User Id and clicks CHECK
2. Read the value (user id) entered by the user and check whether the user id exists in Portal or not, using this code.
IUserFactory userFac = UMFactory.getUserFactory();
boolean userExisFlag = false;
myuserId = <value entered by the user>;
try
{
userFac.getUserByLogonID(myuserId);
userExisFlag = true;
}
catch(NoSuchUserException ex)
{
userExisFlag = false;
}
catch(UMException umEx)
{
// Exception Handling logic
}
finally
{
if(userExisFlag)
{
// User exists is Portal
}
else
{
// User does not exists in Portal
}
}
<b>Note: Add com.sap.security.api.jar JAR file to your project (Project->Properties->Add External Jars)</b>
Thanks
Senthil
P.S: Rewards Points for useful answers.
Message was edited by: SenthilKumar Radhakrishnan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.