Web Part to show upcomming birthdays in SharePoint
I’ve created a SharePointology project on Codeplex.com.
It is a project that aims at giving SharePoint users an even more user-friendly experience by providing a useful collection of SharePoint extensions and SharePoint developers some examples on how stuff is done.
My first contribution to this project will be a webpart called SPOShowBirthdayWebPart, it is a webpart that will display all users whose birthday is coming up in x days.
Download SPOShowBirthdayWebPart v1.0.
Prerequisites
This webpart uses the RunWithElevatedPrivileges function to impersonate the administrator in SharePoint Server 2007. After you do this, you may receive the following error message when you try to enumerate all user profiles:
“Access Denied. Only an administrator may enumerate through all user profiles.”
Microsoft released a hotfix package for this bug “SharePoint Server 2007 hotfix package: May 8, 2008″,
http://support.microsoft.com/kb/952294
If you like this post then please consider subscribing to my full feed RSS. You can also subscribe by Email and have new posts sent directly to your inbox.
January 28th, 2009 at 04:35
after installation, while adding the webpart to a webpart zone, I receive a ‘unable to add selected webpart’ Cannot import SPOBirthdaywebpart why? help me please
thanks
January 28th, 2009 at 08:16
Hi Mariano,
Try this:
* Go to your Main Page, Choose “Site Actions”, “Site Settings”, “Modify All Site Settings”
* In the column “Galleries”, choose “Web Parts”
* Click “New”
* Check the “Overwrite if file already exists?”
* Look for the SPOShowBirthdayWebPart and check this too
* Click the button “Populate Gallery”
* Try adding the web part to a webpart zone.
Let me know if this works or not. Thanks.
Regards,
Erwin
January 31st, 2009 at 02:37
Hi Erwin,
Thanks for the webpart, works a treat. I too had the same error that Mariono had but was easily fixed following your instructions. I have one question though, it is possible to display the user’s Full Name (that is first name and Last name). At the moment, the user’s login name is displayed.
Cheers
January 31st, 2009 at 08:31
George,
I will try to implement your suggestions (and those of others) into a next version of this webpart. Watch the blog for updates.
Regards,
Erwin
February 11th, 2009 at 09:02
I have a custom list with a field called Date of Birth in it ? . How do i display that field in your webpart? Because for now it only shows no There are no items to show in this view. Do i have to use the Birthday Column ( from the parent site ) ? Please let me know
February 11th, 2009 at 15:38
Hi Neeaj,
This webpart queries the SharePoint user profiles to determine the birthdays, it doesn’t work with a custom list.
February 13th, 2009 at 06:57
so do i need to enter the user information in the AD , is that what you are saying ?
February 13th, 2009 at 10:44
Neeaj,
Your users should enter their birthday into the “MySite/MyProfile/Details”. Webpart will pick up that User Profile to display the birtdays.
You could enter their birthday for them if you have access to the Central Administration, but that would be a lot of work.
March 17th, 2009 at 10:02
When any user enters February 29 as the birthday, the webpart displays the following “Year, Month, and Day parameters describe an un-representable DateTime.”? Pls comment
April 3rd, 2009 at 19:40
I am using this web part. It’s very usefull. However, I have a problem. It takes too much time to show the birthdays. Are there anything that I forgot to do it?.. Please, help me.
April 10th, 2009 at 09:24
Evelia,
This Web part queries all your users for their birthday, do you have a lot of users in your SharePoint?
April 10th, 2009 at 09:27
Ismail,
I’ll try and fix this in the next release, but I was wondering what should be displayed in that case? Any ideas?
April 23rd, 2009 at 14:03
Hello Erwin,
Thanks for great post.
I’m using wss3.0, is it possible to use this web part in wss3.0 and instead to show contact information of the users??
please reply me back to my email address
Thanks
April 26th, 2009 at 13:03
Hi Maya,
I don’t have a WSS 3.0 installation available to test the web part in, but I can tell you it uses UserProfiles, and I think that if WSS has userprofiles the web part should work. Let me know when you tried it out, if it doesn’t work I could try and fix that.
To answer your second question, I’m going to release a new version shortly where the username is a link to the profile of the user. Check my blog for more information.
Regards,
Erwin
May 2nd, 2009 at 10:29
hi again ,
no it did not work
since we don’t have userProfiles in wss.
can this webPart use the user information list in wss?
do you have the time to modify this part for me?
it will be to kind of you
Thanks again
June 24th, 2009 at 19:28
Hi all,
I installed the webpart, but now its showing an ‘object reference not set to an instance of an object’. What could be the problem?
From wich field does the webpart gets the birth day info from?
Thanks,
Joao
July 20th, 2009 at 13:29
Hi Ervin,
Thank you very much for your valuable post, After installing the web part & putting it on the web part zone, it doesn’t show any birthday date & says There are no items to show in this view.
what do i need to do to show the upcoming birthdays,
Please help me,
Deepak
October 27th, 2009 at 09:33
Hi Ervin,
Thank you very much for the SPOShowBirthdayWebPart. After installing the web part and putting it on the web part zone, it doesn’t show any birthday date & says There are no items to show in this view.
I saw this below response:
“Your users should enter their birthday into the “MySite/MyProfile/Details”. Webpart will pick up that User Profile to display the birtdays.
You could enter their birthday for them if you have access to the Central Administration, but that would be a lot of work.”
My question is: we have disabled the MYSITE link on our Sharepoint intranet, and so the users will not have be able to add their info on their own profiles. Can this webpart be linked directly with AD?? Or can we link the webpart to a list which already has this data??
Thank you so much
February 2nd, 2010 at 13:26
[...] Web Part to show upcomming birthdays in SharePoint [...]
February 4th, 2010 at 16:15
Thank you! Good instructions and good web-part! It really works.
Спасибо! Хорошие инструкции и отличная веб-часть! Все работает как надо.
February 6th, 2010 at 01:45
It works excellent for me. Thanks
March 25th, 2010 at 09:23
gr8 work.. i have implement in moss2007. cannot resolve the Access denied issue. cant find any download link for the update you have given]
Thanks