Related Posts Plugin for WordPress, Blogger...

About

Follow Us

Friday, 6 February 2015

Introduction: 
It is always good practice to confirm before deleting any record e.g. sometimes by mistake you can press the delete button that can delete important records from your website so it is always suggested that there should be confirmation to delete.


Place a button control on the design page(.aspx)  and write as:

<asp:Button ID="btnDelete" runat="server" Text="Delete"
CausesValidation="False"
onclientclick="return confirm('Are you sure you want to delete?')" />


Now whenever you click on delete button it will prompt the confirmation of deletion. If you confirm, then code to delete record will get executed otherwise not.
Categories: ,

0 comments:

Post a Comment