Just starting out trying the AJAX prometheus stuff and not quite sure what I'm doing, and am getting an error.
I have a link button that is causing an update to a RadAjaxPanel.
Inside that panel is an asp:Literal that I have spit out an iframe tag.
So on my linkbutton click event I have it change the innerHTML of the aspLiteral to update the iframe.
But I'm getting an error stating:
A Runtime Error has occured.
Do you wish to Debug?
Line 604
Error: Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed. Common causes for this error are when the response is modified by calls to Response.Write(), response filters, HttpModules, or server trace is enabled.
Details: Error parsing near "JOHN - kDNATM230|upda'.
I'm just trying to over right an iframe tag inside a aspLiteral, any ideas why im getting this?
I have a link button that is causing an update to a RadAjaxPanel.
Inside that panel is an asp:Literal that I have spit out an iframe tag.
So on my linkbutton click event I have it change the innerHTML of the aspLiteral to update the iframe.
But I'm getting an error stating:
A Runtime Error has occured.
Do you wish to Debug?
Line 604
Error: Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed. Common causes for this error are when the response is modified by calls to Response.Write(), response filters, HttpModules, or server trace is enabled.
Details: Error parsing near "JOHN - kDNATM230|upda'.
I'm just trying to over right an iframe tag inside a aspLiteral, any ideas why im getting this?
6 Answers, 1 is accepted
0
John
Top achievements
Rank 1
answered on 18 Jan 2008, 09:43 PM
Ok, so this is the first time that an error msg from microsoft actually provided beneficial info. I had a Response.Write on my page...so nothing to see here, move along.
0
John
Top achievements
Rank 1
answered on 18 Jan 2008, 11:08 PM
I have another questions about this stuff now.
How do I determine that a ajax call has been made so I can alter my Page_Load accordingly.
in my page_load function I put this in
if (!Page.IsPostBack)
{
write message to screen
}
if (Page.IsPostBack)
{
write different message to screen
}
when I click i get both messages. How do I stop the IsPostBack function from occuring?
How do I determine that a ajax call has been made so I can alter my Page_Load accordingly.
in my page_load function I put this in
if (!Page.IsPostBack)
{
write message to screen
}
if (Page.IsPostBack)
{
write different message to screen
}
when I click i get both messages. How do I stop the IsPostBack function from occuring?
0
Hello John,
Since an ajax call preserves the Page life cycle, the IsPostbBack check will be true on ajax call as well. The way to check for an ajax call is using the RadAjaxControl.IsAjaxRequest.
Greetings,
Steve
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
Since an ajax call preserves the Page life cycle, the IsPostbBack check will be true on ajax call as well. The way to check for an ajax call is using the RadAjaxControl.IsAjaxRequest.
Greetings,
Steve
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
0
John
Top achievements
Rank 1
answered on 22 Jan 2008, 02:18 PM
This doesn't seem to be working for me.
What I have is a panel that is preloaded with content. Then I have links outside of that panel that call ajax stuff, and I want on the ajax postback to clean out the contents of that panel and put in new panel, but I can't clean out the old contents. The output of the literal below is always False, False, I don't seem to detect the ajaxRequest as ever being true.
Here is my page load method
What I have is a panel that is preloaded with content. Then I have links outside of that panel that call ajax stuff, and I want on the ajax postback to clean out the contents of that panel and put in new panel, but I can't clean out the old contents. The output of the literal below is always False, False, I don't seem to detect the ajaxRequest as ever being true.
Here is my page load method
protected void Page_Load(object sender, EventArgs e)
{
if (NavPanel.IsAjaxRequest || FramePanel.IsAjaxRequest)
{
this.Frame.Controls.Clear();
}
else
{
if ((!NavPanel.IsAjaxRequest) && (!FramePanel.IsAjaxRequest))
{
this.MenuMyProfileRow.CssClass = "LeftPaneRowActive";
Literal lit = new Literal();
lit.Text = NavPanel.IsAjaxRequest +
" " + FramePanel.IsAjaxRequest;
this.Frame.Controls.Add(lit);
}
}
this.RadAjaxManagerProxy1.AjaxSettings.AddAjaxSetting(this.MenuMyProfile, this.FramePanel,this.RadAjaxLoadingPanel1);
this.RadAjaxManagerProxy1.AjaxSettings.AddAjaxSetting(this.MenuAlertSettings, this.FramePanel, this.RadAjaxLoadingPanel1);
}
0
Hi John,
It would be best if you could prepare a small sample project, open a support ticket and attach it there. Once we review it, we will be able to advise you on how to proceed.
Greetings,
Steve
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
It would be best if you could prepare a small sample project, open a support ticket and attach it there. Once we review it, we will be able to advise you on how to proceed.
Greetings,
Steve
the Telerik team
Instantly find answers to your questions at the new Telerik Support Center
0
John
Top achievements
Rank 1
answered on 22 Jan 2008, 07:20 PM
Thanks, opened a support ticket, then realized my mistake in targeting the wrong pan in my AddAjaxSettings section.