Capturing javascript events in c #
1 answer
To raise an event from Javascript you need to do the following:
1) Create a hidden asp: button in the aspx page.
2) write the following JS code in the aspx file: var btnHidden = document.getElementById (HiddenButtonClientId); if (btnHidden) {btnHidden.click (); }
Now your button click event will be fired and you can write your desired code there.
+1
Sachin Gaur
source
to share