Requirement: To develop a webpart where in logged in User’s picture appears along with the name.
Sounds simple but if you need to develop without touching User Information Rights (what is this?..we’ll come to it later) then it is not simple.
Step 1: Start Visual Studio 2010 and create a new Empty SharePoint Project. Once you have given the name of the project, it will ask for the Site to be deployed in. Mention the Site and select “Deploy as a Farm Solution” and click OK. Your new Project will be created and you can see the below in your solution explorer
Step 4: We need to write the related code for the webpart in code behind page of the ascx file which will be automatically understood by the webpart’s code file.
Add Microsoft.Office.Server and Microsoft.Office.Server.UserProfiles in the reference. We need to be using a reference in the code as well. Detail coding will be presented in Part 2…