Skip to content

SharePoint 2013 Sample Users with Photos

04/19/2013

In my last post about my new demo rig and demo/dev environments I mentioned that I would be putting together various “content packs” that I could use to automatically add content and users to my demo environments.  In that spirit I’ve started by creating some scripts and assets to add 50 sample users along with their photos to Active Directory (AD) and the SharePoint 2013 User Profile store.

Because I’m pompous, I chose to use 50 of history’s famous authors as the sample users 😉   True, it doesn’t make for a “realistic” experience, but it tickles me to see Shakespeare and Steven King collaborate on documents together.

The package I created can be found here on CodePlex.

In the package you’ll find:

  • A CSV file with all the test users
  • A PowerShell script that iterates over the users in the CSV and adds them to AD
  • A folder containing all the photos of the users
  • A PowerShell script mapping the user photos to the new sample users

To add the users:

  • Change variables in the AddUsersToAD.ps1 script appropriate to your environment and run on the domain controller to add users to the domain
  • Configure and run your UPS Sync as you normally would
  • Drag the photos in the UserPhotos folder into the User Photos folder (typically http://[host name]/User%20Photos/)
  • Change variables in the Map_User_Photos.ps1 script appropriate to your environment and run on a SharePoint Server
  • You should now have 50 new users in SharePoint with photos

Obviously I could have automated this more and even added  more options but this was enough for me.  I can add users to any environment within 15 minutes or so.

Hope it proves helpful for some of you!

 

See screenshot below…

Authors

Advertisements
Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: