摘要:
http://blog.the-dargans.co.uk/2007/04/programmatically-adding-items-to.htmlhttp://asadewa.wordpress.com/2007/11/19/adding-a-custom-content-type-specific-item-on-a-sharepoint-list/Short walk through:Get a instance of the list you want to add the item to.Add a new item to the list:SPListItem newItem = 阅读全文
posted @ 2012-07-24 20:57
Black Bean
阅读(142)
评论(0)
推荐(0)
摘要:
SPContentTypeId id =newSPContentTypeId(BaseContentTypeId);IList<SPContentType>ContentTypes= web.ContentTypes.Cast<SPContentType>().Where(c => c.Id.IsChildOf(id)).ToList();using(SPSite site =newSPSite(SPContext.Current.Site.Url)){ using(SPWeb web = site.OpenWeb()) { SPContentTypeCollec 阅读全文
posted @ 2012-07-24 20:55
Black Bean
阅读(158)
评论(3)
推荐(0)
浙公网安备 33010602011771号