How to Add Message and Confirmation Boxes Using JavaScript?
Answer / 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 |
code to create a new window
snippet to prevent submission of form when certain/any validations got failed
code to Hide and Show form controls
how to get the User's Time of Day
determine which Element received an Event
code to detect versions of different browsers like internet explorer, netscape, mozilla, opera etc
code to set the main window's size
how to copy form data between different pages
how to determine which Mouse Button was pressed
function to combine two or more arrays
How to Add Message and Confirmation Boxes Using JavaScript?
how to create Expandable and Collapsible Menus