摘要: 前面的文章中有说到,需要对WSS进行高级别的操作时,我们可以使用SPSecurity.RunWithElevatedPrivileges来提高操作权限级别! 直接使用--SPSecurity.RunWithElevatedPrivileges(delegate() {代码});提高权限将是让代码以sharepoint\system所具有的权限来执行!现在让我们来做一个示例:MOSS服务器: htt... 阅读全文
posted @ 2010-01-27 15:51 绿森林 阅读(619) 评论(0) 推荐(0) 编辑
摘要: 1.查询列表的所有字段view plaincopy to clipboardprint?SPSite site = new SPSite("http://mosssite/"); SPWeb web=site.OpenWeb(); SPList list = web.GetList("/Information"); foreach (SPField sf in list.Fields) {... 阅读全文
posted @ 2010-01-27 09:44 绿森林 阅读(549) 评论(0) 推荐(0) 编辑