Skip to Content
0
Former Member
Aug 08, 2005 at 03:40 AM

UniqueID -> UME

11 Views

Iam struggling to get UniqueID or UID when i know Display Name of a user in Portal.

Is it through ISearchResult?

//dname is the string -> Display Name of User

try{
			
	IUserSearchFilter userFilt = userFact.getUserSearchFilter();
	userFilt.setDisplayName(dName,ISearchAttribute.EQUALS_OPERATOR, false);

	ISearchResult result = userFact.searchUsers(userFilt);
	
	if(result.getState()==ISearchResult.SEARCH_RESULT_OK){
	
		while(result.hasNext()){
			String uniqId= (String) result.next();
			IUser thisUser = userFact.getUser(uniqId);
			response.write(thisUser.getDisplayName().toString());
		}
	}
}catch...........

How wud i catch UniqueID of a user??

Somebody plz hint me ...