Code Behind, VB.Net
btnNext.Attributes.Add("onclick", "Confirmation(this,'" + GetLocalResourceObject("msg").ToString() + "')")
.ASPX Page [Java Script Tags]
function Confirmation(source, msg) { $(source).easyconfirm({ locale: { title: 'Confirm', text: msg} }); $(source).click(function() { var result = $(source).attr('tag'); $('#<%=hidField.ClientID%>').val(result); }); }
Jquery Version jquery-1.4.4.min.js jquery-ui-1.8.7.min.js
Beside this i am using jquery.easy-confirm-dialog to display this message box [Yes / No]. jquery.easy-confirm-dialog : http://www.projectshadowlight.org/jquery-easy-confirm-dialog/
hidField : Refer code for asp page above
On IE 8 : Message box gets displayed and it takes me to the respective pages based on what I clicked. [ yes/no].hidField is used in the code behind to get the yes/no response and show the appropriate page. This works perfectly in IE8
On IE 9 : Message box does not gets displyed and it takes me to a page , as if I have clicked no. hidField value is zero for no. So in case no value is set it thinks the I have clicked no and executes the code for it.
I debugged it on IE9 and what I found was that the Message gets displayed [while debugging only], but it does not stop the execution of code and wait for user response and then move forward. It continues execution while the message is displayed [debug mode, so I was able to see it]. and since default value of hidField is 0 it redirects to the appropriate page.
Any suggestion / reason why this could be happening. Is there other reason other than what I have mentioned above ? Any possible solution
1