Rank: Advanced Member Groups: Member
Joined: 10/14/2010 Posts: 19
|
Support,
First have to save the message box is awesome!
Question, if the user clicks the 'X' to close the window I need it to post back because I need this to be handled like cancel to reset some drop down list values.
How do I cause a post-back if the X is clicked or disable the closing of the window until the user clicks Yes or Cancel only?
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi, You can handle the message box's ClientSideOnCancel to achieve that. If you just want to disable the close button, you can return false from your ClientSideOnCancel event handler. It will be something like this:
Code: JavaScript
function on_cancel()
{
return false;
}
Code: HTML/ASPX
<eo:MsgBox ClientSideOnCancel="on_cancel" ....>
....
</eo:MsgBox>
If you wish to raises a post back when user clicks "X", you can do so in your on_cancel function. If you are not familiar with raising post back with JavaScript, we have a free ScriptEvent control in the package to help you to do that: http://doc.essentialobjects.com/library/1/eo.web.scriptevent.aspxHope this helps. Thanks
|