Hi. I have a simple page, that I moved to asp.net 2.0 and to a masterpage/content page design. I'm trying to get a simple confirmation popup to work and have tried both onclientclick in the button on the markup and in attribute add in the page load, neither are working.
my code:
===in markup
<asp:Button OnClientClick="return confirm('OK to Delete?');" ID="DeleteButton" SkinID="Button" runat="server" CommandName="Delete" Text="Delete" OnClick="Delete"></asp:Button>
=== from code:
DeleteButton.Attributes.Add("onClick", "return confirm('Are you sure?')")
What up?
Thanks for any help or information!
....