Update Panel Problem
-
Hi There, I had Created A Message box using div tag to show error messages.It display erro messages properly.But when I try to show any error in update panel then it didn't show this error message box.Can anybody tell me what is the problem. Thanks.
-
Hi There, I had Created A Message box using div tag to show error messages.It display erro messages properly.But when I try to show any error in update panel then it didn't show this error message box.Can anybody tell me what is the problem. Thanks.
-
Hi There, I had Created A Message box using div tag to show error messages.It display erro messages properly.But when I try to show any error in update panel then it didn't show this error message box.Can anybody tell me what is the problem. Thanks.
-
It is not possible to show an alert box from code behind on using the update panel. Update Panel just blocks these alerts. Can you provide me with the code snippet so that i shall try to help you.
-
-----------------This the code which I had written in CommonClass where all my commonly used method stored.------------------------------------------------- public static void ShowMessageBox(string Message, System.Web.UI.Page p) { System.Web.UI.WebControls.Label lblMessageBox = new System.Web.UI.WebControls.Label(); lblMessageBox.Text = "" + Environment.NewLine + " void(showBox('" + Message + "'))"; p.Controls.Add(lblMessageBox); } ---------------------This is my Code Behind Code-------------------------------- CommonClass.ShowMessageBox(ex.Message.ToString(), this.Page); By using this code I am calling method present in Common Class. --------------------------And This Is My Message Box Code Which I had written On Master Page--------------------------------------- function showBox(str) { var width = document.documentElement.clientWidth + document.documentElement.scrollLeft; var layer = document.createElement('div'); layer.style.zIndex = 2; layer.id = 'layer'; layer.style.position = 'absolute'; layer.style.top = '0px'; layer.style.left = '0px'; layer.style.height = document.documentElement.scrollHeight + 'px'; layer.style.width = width + 'px'; layer.style.backgroundColor = 'LightGray'; layer.style.opacity = '.7'; layer.style.filter += ("progid:DXImageTransform.Microsoft.Alpha(opacity=80)"); document.body.appendChild(layer); var div = document.createElement('div'); div.style.zIndex = 3; div.id = 'box'; div.style.position = (navigator.userAgent.indexOf('MSIE 6') > -1) ? 'absolute' : 'fixed'; div.style.top = '200px'; div.style.left = (width / 2) - (400 / 2) + 'px'; div.style.height = '100px'; div.style.width = '400px'; div.style.backgroundColor = 'White'; div.style.border = '4px solid silver'; div.style.padding = '20px'; document.body.appendChild(div); var myimg = document.createElement('IMG'); myimg.src= "../images3.jpg"; myimg.width= '50'; myimg.height = '50'; myimg.visible="true"; div.appendChild(myimg); var p = document.createElement('p'); p.innerHTML = str; p.style.position = "absolute"; p.style.top = '20px'; p.style.fontSize=14+'px'; p.style.fontWeight = "bold"; p.style.left = (width / 2) - (800 / 2) + 'px'; div.appendChild(p); v</x-turndown>