SharePoint

SharePoint is a web-based collaborative platform that integrates with Microsoft Office. Launched in 2001, SharePoint is primarily sold as a document management and storage system, but the product is highly configurable and usage varies substantially between organizations.

Custom Action for Sharepoint Designer

0
I'm going to create a custom action for Sharepoint Designer that creates a discussion thread in a discussion list based on the current list item. I'm going to use the...

SharePoint 2007 basics – Add a Folder

0
Folders can be added under a list or under another folder and the way of adding in each case is very similar. Below another example of sample functions. public SPFolder AddFolder(SPList parentList,...

SharePoint 2007 basics – Add a List

0
Adding a list is done very much in the same way as a web. You just have to pay attention to were you should get your list template from, because depending...

SharePoint 2007 basics – Add a Web

0
For my first SharePoint post I wanted to start by some of the basics related to working with the SharePoint Object Model. For sure there are other posts about this on...

How to upload a list template

0
public static SPFile UploadListTemplate(string siteUrl, string templatePath) { using (SPSite site = new SPSite(siteUrl)) { SPDocumentLibrary templates = (SPDocumentLibrary)site.GetCatalog(SPListTemplateType. ListTemplateCatalog);  System.IO.FileInfo fileInfo = new System.IO.FileInfo(templatePath); byte bytes = System.IO.File.ReadAllBytes(fileInfo.FullName);  return templates.RootFolder.Files.Add(fileInfo.Name, bytes); } }

How to upload a site template

0
public static SPFile UploadWebTemplate(string siteUrl, string templatePath) { using (SPSite site = new SPSite(siteUrl)) { SPDocumentLibrary templates = (SPDocumentLibrary)site.GetCatalog(SPListTemplateType.WebTemplateCatalog);  System.IO.FileInfo fileInfo = new System.IO.FileInfo(templatePath); byte bytes = System.IO.File.ReadAllBytes(fileInfo.FullName);  return templates.RootFolder.Files.Add(fileInfo.Name, bytes); } }

How to create an item in a discussion list

0
Creating a discussion in discussion list is different from creating a simple list item. The code for creating a discussion item is: using (SPSite site = new SPSite("SITE URL")) { ...

Built-In ContentType and Field Ids

0
Only today that I've found that the WSS object model has 2 classes that hold all the IDs of the built-in ContentTypes and Fields. Instead of doing things like this: SPListItem...

ItemUpdating, AfterProperties and field names

0
I was checking for a field value change in a WSS V3 list with the help of event handlers with no success. In the ItemUpdating event, the list item has...

How to add a group to a WSS v3 site

0
Get the group SPGroup group = web.SiteGroups; Create a role assignment SPRoleAssignment newRoleAssignment = new SPRoleAssignment(group); Add the role definition (Full Control, Read, Contribute, …) to the role assignment newRoleAssignment.RoleDefinitionBindings.Add(web.RoleDefinitions); And add the role assignment...