After a user uploads a document the editform.aspx page is displayed. I need to force an update even if Cancel button is selected within the default editform.aspx form of a library. I know there is a preSaveAction function for save, is there a preCancelAction I can call to execute additional code on a cancel? Has anyone tried to force additional code to run even if the user selects cancel button within the default editform? Do i have to maybe capture that buttons event? What is that event? I have been searching and nothing found that matches what I want to do. I have successfully populated custom fields on the form so when the user selects save all is saved but when a user selects cancels i need some of the fields to still store the information. I tried and wrote code to do the save when the editform loads and it works great, but then if the user selects save i get error that the file is already updated by user. so i only want the code to run if i hit Cancel. Help!!!