PreSaveAction Function in SharePoint 2010



PreSaveAction” function is JavaScript function which allow programmer to write code with in this function which will execute just before saving records. Programmers can use this function in NewForm.aspx or EditForm.aspx. If you want to stop saving; the function should return false & if you want to execute save function after this function; return true.

Syntax is:

function PreSaveAction ()
{
     return true; // if you want to execute save functionality of the form.
     
     //return false ;//if you want to stop execution of save functionality of the form.
}

Comments

Popular Posts

SharePoint Interview Questions and Answers

Download Infopath Form Templates

How to get current logged user information using JavaScript ?

Steps to set Form based authentication (FBA) for SharePoint 2010

SharePoint Interview Questions and Answers II

Get List Items - JavaScript

Cross Site List Rollup Web Part for SharePoint 2010

Hide Recently Modified Items

Change Language for current user with JSOM in SharePoint Online

SharePoint 2010 CSS Chart