Monday, 31 October 2011

Customizing SharePoint list form ruined the entire form

Customizing new form or edit form with SharePoint designer, some times ruined entire form if you delete ListFormWebart from the form.
This may also result in affecting other form of the same list.

We encounterd this problem once on our test environment. After searching heavily on internert I found below post which helped me a lot and saved my time.

The post gives you step by step things which you need to follow. Just to add one point, while following these steps make sure you save your work only after last step. Saving your work in between may ruined other form.

Quick Update
In case if you want to customize your edit form or new form, hide the ListFormWebPart control and insert the Custom List Form control to your page.

JavaScript and SharePoint List Form fields

Sometimes we need to hide some of the fields, set default value for fields, get the current value of fields on List new form, and edit form, display form.

We can achieve this using JavaScript.

To start with, Microsoft Team has given a good solution on this post

But there are some catches, when we use code given in above post for controls like check box, multiple line textbox.
There is a very good post on cleverworkaround which has much improved JavaScript to overcome these controls.

To return values for SharePoint field types from newform and editform, below is good post given by Alexander on his blog SharePoint JavaScript

Hope all these information will be helpful for all of you.

Thursday, 20 October 2011

How to add if else if statement in calculated columns of SharePoint 2007

This is what I want to achieve

if(status = "Bad")
then rating = 1
else if(status = "Good")
then rating = 2
else if(status == "Excellent")
then rating = 3

to achieve this I created a calculated column "Rating" and added below formula


And it was returning perfect results required to me.

There are also lots of sample formulas available at below link:
Related Posts Plugin for WordPress, Blogger...