Monday, July 30, 2012

How to create word document from byte array

How to convert byte array to string

Differences between SharePoint Client Object Model vs Server Object Model

While developing one of the web services requirements I was so confused about which classes and object model to used – client object model or server object model. Microsoft provided many control and functionalities for client object model into SharePoint 2010.

After searching little bit online, I have found out that for my web service requirements – server side object model is best (i.e. SPSite, SPWeb).

Here are some good reference links from where we can find the differences between two object model:

Monday, July 23, 2012

How to download documents using SharePoint object model

SharePoint 2010 Document ID Service Feature

SharePoint 2010 provides new functionality for retrieving documents from site collection by document’s unique Ids. For enable this functionalities we need to enable site collection feature “Document ID Service”. After activating this feature, when we create new documents, system will generate and assign unique number to uploaded documents. Document ID service is a very good feature if we want to move document around into site collection, by moving the documents it’s URL is going to change but the Document ID/Unique ID will be same, so we can retrieve the documents using Document ID.

Good reference links:

SharePoint 2010 Migration Error: A duplicate content type name "Resource" was found

During the migration from SharePoint 2007 to 2010 – we received "A duplicate content type name ‘Resource’ was found” error.

To remove this error, we have rename “Resource” content type to “Resource1” into SharePoint 2007 site and restored the content database again to make sure that we were clean for this error.