Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Strange Error message
Message
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
01458427
Message ID:
01458430
Vues:
35
Try with EnableViewState property set to false for new controls.

>Ok, how?
>
>
>>As far as I remember, this error has to do with the ViewState. Try disabling ViewState for these new controls. That's one of the problems with adding new controls in run-time - you may get this error which is very hard to deal with.
>>
>>>I created a user control that has 2 RadioButtonLists and 2 DropDownLists. One set of RadioButtonLists enables one of the DropDownLists. If I drop the control onto a page and run it, it works fine.
>>>
>>>However, we're going to end up with 50+ controls, so I'm adding them to the page at runtime, like this:
>>>
>>>
>>>Control control = LoadControl(ControlName);
>>>PlaceHolder1.Controls.Add(control);
>>>
>>>
>>>
>>>When I click either of the RadioButtonLists or DropDownLists I get
>>>
>>>
>>>---------------------------
>>>Microsoft Internet Explorer
>>>---------------------------
>>>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 '<!DOCTYPE html P'.
>>>---------------------------
>>>OK  
>>>--------------------------- 
>>>
>>>
>>>I Googled it and found this, http://weblogs.asp.net/leftslipper/archive/2007/02/26/sys-webforms-pagerequestmanagerparsererrorexception-what-it-is-and-how-to-avoid-it.aspx, but this is all greek to me. I have no clue what's wrong
>>>or how to fix it.
>>>
>>>Help!
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform