Hello!
I have build a control that works as fileuploader. Inside the control I want to ensure that the control is not updated with a radajaxmanager that is placed on the page where the control is inlcuded.
I made a recursive FindControl method to find the RadAjaxManager from the Control hierarchy, now I want to add this conditional Postback eventhandler to the radajaxmanager:
RadAjaxManager mgr = (RadAjaxManager) this.FindControl(this, typeof(RadAjaxManager));
if (mgr != null)
{
mgr.ClientEvents.OnRequestStart =
"function conditionalPostback(sender, args) { "
+"if(args.EventTarget == \"<%= btnAddFile.UniqueID %>\")"
+"{"
+" args.EnableAjax = false;"
+"}"
+"}";
}
This doesn' work, I always encounter the javascript error: " '}' needed" when I load the page.
Is there an other possibility to avoid an ajax request by a control? I really need this feature!
Thx in advance & kind regards
I have build a control that works as fileuploader. Inside the control I want to ensure that the control is not updated with a radajaxmanager that is placed on the page where the control is inlcuded.
I made a recursive FindControl method to find the RadAjaxManager from the Control hierarchy, now I want to add this conditional Postback eventhandler to the radajaxmanager:
RadAjaxManager mgr = (RadAjaxManager) this.FindControl(this, typeof(RadAjaxManager));
if (mgr != null)
{
mgr.ClientEvents.OnRequestStart =
"function conditionalPostback(sender, args) { "
+"if(args.EventTarget == \"<%= btnAddFile.UniqueID %>\")"
+"{"
+" args.EnableAjax = false;"
+"}"
+"}";
}
This doesn' work, I always encounter the javascript error: " '}' needed" when I load the page.
Is there an other possibility to avoid an ajax request by a control? I really need this feature!
Thx in advance & kind regards