During installation of the Web Part templates, you will be prompted for the location of Microsoft.SharePoint.dll. This assembly is located in Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\ISAPI\ on your SharePoint (WSS/SPS) Server. You might need to copy Microsoft.SharePoint.dll to your development PC from the server with SPS or WSS installed.
Creating the Web Part Project
Web Parts should be built using the Web Part Library project. So let’s go ahead and create this project.
In Visual Studio .NET, select Create New Project (Shift + Ctrl + N).
Select the project type as Visual C# Projects, and choose the new Web Part Library template from the right-hand pane.
Name the new project ExtensibleMCMSPageListingWebPart, and place the project directory under My Documents\Visual Studio Projects.
Once our new project is created, we can see a variety of files and references that have been created by the template:
Some of the most important of these are:
Microsoft.SharePoint—SharePoint’s main API
System.Web—.NET Framework namespace holding classes for web operations
System.Xml—.NET Framework namespace holding classes for XML operations
AssemblyInfo.cs—used to define the metadata of the assembly and to specify a key file to sign it.
Manifest.xml—used to populate CAB files during the deployment process.
WebPart1.cs—an empty Web Part template similar to the Class1.cs file created when using a Class Library template.
XML file used when deploying Web Parts to Windows SharePoint Services.
It contains the references to the assembly name and the class name used
by the Web Part.
You can delete the following files from the solution: WebPart1.cs, WebPart1.dwp, and Manifest.xml, as we will create our own later on.