Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SharePoint User Process Access Issue on Multi User Profile environment.

Status
Not open for further replies.

adnan119

Programmer
Nov 8, 2002
1
US
I have to access user profile application for user profile manipulation by Power shell.

Environment
I have two user profile application installed in my farm.

I wrote this code:

$site = new-object Microsoft.SharePoint.SPSite(" GUID XXXXXXXXXX);
$ServiceContext = [Microsoft.SharePoint.SPServiceContext]::GetContext($site);
$ProfileManager = new-object Microsoft.Office.Server.UserProfiles.UserProfileManager($ServiceContext)

The Problem is this code always point to the same (first created user profile).
I changed the GUID to point to the second profile application but it point that.

Please Help.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top