I have been playing around with LINQ in Sharepoint object model and I have to say I’m quite impressed. It does shorten the amount of code we write and works just as great or better.
A handy way to select distinct records from SPListItemCollection set queried from CAML query.
Sharepoint has a feature that allows us to migrate list data structure and content to a different site so that we do not have to re-create them. This is done through list settings -> save list as template. List template is a powerful function which can save the data structure of a list as well as its content.
Lately we found a very interesting fact of Sharepoint, which I think is worth writing a post about. Although it is very rare that someone will read directly into Sharepoint database to retrieve information, but for some hardcore users, especially with my last post regarding how Sharepoint stores data in backend database, one can easily read into Sharepoint Prod_Content database and do CRUD transactions.
I spent quite some time today fixing this problem of accessing a list item in parent web. What I had to do was to access a list item in a parent web, but it kept crashing as if there's no permission given to access it.
Time and time again, I use these methods in coding for Sharepoint. These include methods for querying a list, bind a Dropdown List to a list, and bind a Dropdown List to a multiple choice field.
This is an extremely useful function, which allows you to read an Excel spreadsheet and convert its data into a DataTable in C#. With data in a DataTable, we can perform lots of things to it.
I had the problem of saving files which I uploaded programatically to Sharepoint list item. When I tried to save them, there's pop up dialog saying the file is in read only mode, even I had all the required permissions.
I had the problem of page not able to redirect when in an ajax postback. It happens to be the fact that I disabled a line in web.config:. This line should be added in HttpModules, so that redirection will work in Ajax postback. This class manages HttpModules for Ajax functionalities in ASP.NET.
A useful function to send email in Sharepoint, programatically.