fires before the user clears the list of files to upload (clicks the button )
myForm.attachEvent("onBeforeClear", function(){ // your code here return true; });
returning false will cancel the 'clear' operation