Link to home
Start Free TrialLog in
Avatar of SP
SP

asked on

SharePoint

Some usernames (claims encoding) in SharePoint sites are showing up like "i:0#.w|domain\username". How can remove  this part "i:0#w|" ? I want usernames to show up like simple "domain\username".
Avatar of Mohit Nair
Mohit Nair
Flag of India image

If your site is using claims based authentication then its likely to have those special characters. Please check if you have configured user profile service application. Once you have sync connection configured in user profile service, perform a full crawl of profiles and check .
Avatar of SP
SP

ASKER

Thanks Mohit. Site is using claims based authentication. Yes we do have user profile service application and crawling is already in place, still we can see special characters. Will that get removed if I do full crawl again and why?
If this is SharePoint Standard or Enterprise, have you configured the User Profile Service?
  If this is Foundation, use Set-SPUser to set the DisplayName of the account.
also look at http://dinushaonline.blogspot.com/2013/10/convert-claims-based-login-name-in.html
Avatar of SP

ASKER

Jayaraja - It's SP enterprise. Yes we do have user profile service application and crawling is already in place. How can I use Set-SPUser in this case?
ASKER CERTIFIED SOLUTION
Avatar of Jayaraja Jayaraman
Jayaraja Jayaraman
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of SP

ASKER

I tried above powershell. It ran fine but nothing changed. I can still see special characters "i:0#.w. Any idea?
go the user profile property via CA and see what the display name is set to?
Avatar of SP

ASKER

Property name - Name
Property Type - String (single Value)

Is that you looking for?
Avatar of SP

ASKER

FYI - This user already has a user profile
Hi, I solved it with an Inherit function       "fn-Substring(Variable where the string is,4,25)"   The number 4 is the first character of your desire string and 25 the last character this mean your string will bre from the character 4 to the character 25 in this example.

Also you can create an User defined action, where you can get the login name of an user and with the function "Display name" you can save it in an outpout variable with just the name.