Hi,
I have a WebAsynchronousRefreshPanel and few controls(Button Controls) within it.
I have few controls outside WARP as well.
Have used WARP in order to prevent refreshing the entire Page.
In case of any errors/Exceptions at the server side, A client side function is invoked to display exception.
Following is the Server side code to invoke client side exception:
ScriptManager.RegisterClientScriptBlock(Page, GetType(), "CLOSE_SCRIPT", "DisplayAlertBox('" + Message + "');", true);
And this is the Client side code to display the Message in form of Alert Box:
{
alert(arg1);
}
But there is a problem displaying exception incase of exception from a control inside WAPR.The error/exceptions are not getting displayed on to the Client side.It works fine for controls outside WARP.
As displaying error is a must for any controls.. I dont know how to go about this. The controls needs to be inside WARP at any cost.
Any suggestions would be valuable.
Thanks In Advance.
Within async postback of WARP or WebTab, you can not use standard Register... methods. To pass script to client you may add to WARP a literal control with your javascript statements use Infragistics.WebUI.Shared.CallBackManager.AddScriptBlock(..) with your scipt. You also may process ClientSideEvents.Error events of WARP.
Note: if there is a global server error while async postback of WARP, then full postback will be triggered. Besides client error processing, you may process those global errors on server using Infragistics.WebUI.Shared.CallBackManager.AddErrorHandler(...)
Thanks..Infragistics.WebUI.Shared.CallBackManager.AddScriptBlock(..) worked fine in my case for invoking client side function.
But i have one more Query. I want to invoke a WebDialogWindow (i.e make a WebDialogWindow visible from a server side which is hidden initially) by a control that is within WARP. Currently its not working fine. Could you please provide me with suggestions.
Thanks again.
Regards,
Nuthan.