How to Add Message and Confirmation Boxes Using JavaScript?
Answer Posted / guest
public void AddConfirmMessage(WebControl ctl, string
message)
{
ctl.Attributes.Add("onclick", "if ( ! confirm( '"
+ message + "' )) return false; ");
}
public void AddPopupMessage(WebControl ctl, string message)
{
ctl.Attributes.Add("onclick", "alert( '" + message
+ "'); ");
}
Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
code to get the coordinates of a Click Event
Reading which Non-Character Key was pressed
Create a Menu that can be activated while clicking on Right Mouse button
how to create Expandable and Collapsible Menus
how to Auto Scroll the page
how to convert between arrays and strings
sample code to auto focusing the first field in a form
how to copy form data between different pages
program to bring a window to the front
How to block double clicks
code to Hide and Show form controls
advance the focus to next consecutive fields when Enter Key is pressed
code to keep a page Out of the browser history
how to get the User's Time of Day
Create a ViewState Property?