Note that there are some explanatory texts on larger screens.

plurals
  1. POJavascript Error after using Script Manager- : The message received from the server could not be parsed
    primarykey
    data
    text
    <p>I am opening a ShowModalDialog on a button OnClientClick event and the javascript for it is:-</p> <pre><code>&lt;script language="javascript" type="text/javascript"&gt; function openmodalWinLunch() { var variable1 = "Lunch"; window.showModalDialog("ClockPopUP.aspx?code=" + variable1, "dialogWidth:290px;dialogHeight:270px,"); } </code></pre> <p></p> <p>On the Clock.aspx page i have a asp button on which i had written code :-</p> <pre><code>protected void btnStop_Click(object sender, EventArgs e) { _nonProduction = new NonProduction(); if (Session["LastNonProdTimeID"] == null) { } else { int NonProdTimeEntryID = Convert.ToInt32(Session["LastNonProdTimeID"]); //Updating the TimeSpent isTimeSpentUpdated = _nonProduction.UpdateTimeSpentInDB(NonProdTimeEntryID); if (isTimeSpentUpdated == true) { string timespent = Convert.ToString(_nonProduction.GetTimeSpent(NonProdTimeEntryID)); //string msg = "Total time consumed in " +HiddenTaskname.Value.ToString()+": " + timespent.ToString() + " Minutes"; Response.Write("&lt;script language='javascript'&gt;window.close();&lt;/script&gt;"); Response.End(); } else { } } } </code></pre> <p>Preveously every thing is working fine and this code is working as per my requirement. Just i had added Scriptmanager on the Clock.aspx as i m showing a clock which shows the elapsed time to the user. After that when i m clicking on the btn_Stop on CLock.aspx page i am getting this error message:-"Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed."</p> <p>Please guide me that how i solve this issue.</p> <p>I found that what is the root cause of this error. It is happening because i m using Resonse.Write and other information is <a href="http://weblogs.asp.net/leftslipper/archive/2007/02/26/sys-webforms-pagerequestmanagerparsererrorexception-what-it-is-and-how-to-avoid-it.aspx" rel="nofollow">Here</a></p> <p>Guide me that how i fix this as i want to close the webpage after button click event.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload