views:

1391

answers:

2

Hi,

I have modified my MOSS 2007 configuration to query a given target AD successfully. I would like to show some custom LDAP fields (such as country) in the PeopleEditor control and allow users to search against these fields. Can someone point me towards useful resources/tutorials showing how to do this?

Thanks, MagicAndi.

A: 

A first step should be to map the fields form the AD to a attribute in the SharePoint user profile. You can do this in the configuration of the Share Service Provider (Central Administration > Shared Services > User Profiles and Properties).

There you add a new attribute and define which AD field should be mapped to it. You can also define which fields the users are allowed to override (but only in SharePoint, it's only a one ways synchronization) and which one are read only.

This blog post shows how to configure the SharePoint search to be able to search users by a custom attribute in the user profile.

I hope this will point you into the right direction.

Flo
@Flo:You are right at what you said, but his question is to exposing those fields in the People picker control. Not in the People search as you mentioned
Kusek
Kusek, beat me to it. Flo, thanks for answering, but I am specifically looking at modifying the PeopleEditor control.
MagicAndi
+3  A: 

You need to inherit from the EntityEditor control (just as PeopleEditor does) and write your own queries and validation.

Some background (read community content):

Along with these links and carefully studying the PeopleEditor control with Reflector, another good resource is this blog post from Igor Kozlov. There's a less detailed but still useful example on MSDN here.

I'm working on a CodePlex project that queries any given Active Directory from a people picker. It's well documented and combines techniques from the various references out on the web (giving credit of course). Hope it helps someone as well!

Alex Angas
Alex, Thanks for answering. I had already came across Igor's post and had started work using the EntityEditor, based on Igor's post. +1
MagicAndi
Alex, accepted as answer. Sorry for the delay!
MagicAndi