开发环境 : .netFramework 2.0/3.0/3.5 + Vs2005 + sharepoint server 2007
需要下面两个组件中任意一个组件
Windows SharePoint Services 3.0 Tools: Visual Studio 2005 Extensions
Windows SharePoint Services 3.0 工具:Visual Studio 2005 Extensions 1.1 版
前者组件为英文版,使用HtmlWriter 直接输入Webpart,而后者为中文版且可以封装了Asp.net控件,通过这两组件创建的,此文按照后者为例说明
WSS 类库项目部署时(F5)完成了以下操作:(组件安装后由Vs部署自动完成)
l 生成Web Part组件
l 将Web Part解决方案打包成Windows SharePoint Services Feature。
l 如果这个Web Part解决方案以前部署过,扩展将取消以前版本的Web Part解决方案的Feature。
l 将Web Part组件安装到GAC中。
l 在Windows SharePoint Services部署并激活Web Part解决方案Feature。
l 将Web Part加入到SafeControls列表中。
l 调用iisreset命令重新启动Microsoft Internet Information Services (IIS)。
l 将调试附加到w3wp进程上。
手动部署MOSS 2007 WebPart
开发环境配置好后
首先创建Share point project
![](https://i-blog.csdnimg.cn/blog_migrate/56c2c2c8a2b7260f0f7b49293c0f4880.gif)
该项目中 * .webpart 可以修改webpart 相关说明信息
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
若是英文版的组件修改webpart信息 通过项目属性中的 SharePoint Solution 修改
![](https://i-blog.csdnimg.cn/blog_migrate/f6fc47872740e8d24608c0a7bcf9e512.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/ContractedBlock.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedBlockStart.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedBlockStart.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/ContractedBlock.gif)
![](https://www.cnblogs.com/Images/dot.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedBlockEnd.gif)
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
创建好你的webpart 后 ,部署项目
部署和调试Web Part
1.按F5。扩展将自动生成、部署、初始化Web Part解决方案Feature调试。
2.打开在SharePoint站点中想要添加Web Part的Web部件页面。
3.在Web部件页上点击网站操作,选择编辑页面。
4.在向要添加Web Part的Web Part Zone中添加Web Part。
5.在弹出的添加Web部件页面中,在所有Web部件部分中的杂项中找到我们的Web Part,单击确定。
其他资源
应该可以使用类似*ascx(UserControl)方式来实现WSS webpart 但一直没有做好,有兴趣的可以参考一下UserControl to WSS webpart
Microsoft Windows SharePoint Services Developer Center