http://www.microsoft.com/downloads/details.aspx?FamilyID=CAC3E0D2-BEC1-494C-A74E-
75936B88E3B5&displaylang=en
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.
1. | In Visual Studio .NET, select Create New Project (Shift + Ctrl + N).
|
2. | Select the project type as Visual C# Projects, and choose the new Web Part Library template from the right-hand pane.
|
3. | Name the new project ExtensibleMCMSPageListingWebPart, and place the project directory under My Documents\Visual Studio Projects.
|
4. | Click OK.
|
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:
References to:
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.
WebPart1.dwp—an
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.