Click here to Skip to main content
15,886,199 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
ERROR:

Invalid posted data for current ObjectList ViewMode. (The ObjectList may have been databound on postback during Page_Load, resetting the ViewMode. Call DataBind in Page_Load only if IsPostBack is false.)
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Exception: Invalid posted data for current ObjectList ViewMode. (The ObjectList may have been databound on postback during Page_Load, resetting the ViewMode. Call DataBind in Page_Load only if IsPostBack is false.)

Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. 

Stack Trace:
[Exception: Invalid posted data for current ObjectList ViewMode.  (The ObjectList may have been databound on postback during Page_Load, resetting the ViewMode.  Call DataBind in Page_Load only if IsPostBack is false.)]
   System.Web.UI.MobileControls.Adapters.HtmlObjectListAdapter.HandlePostBackEvent(String eventArgument)
   System.Web.UI.MobileControls.ObjectList.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument)
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
   System.Web.UI.MobileControls.MobilePage.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)
   System.Web.UI.Page.ProcessRequestMain()


[edit]text block added[/edit]
Posted
Updated 15-Nov-12 23:10pm
v2
Comments
Kschuler 16-Nov-12 9:41am    
If you really want help with this, you should tell us more about what you are doing. Post the relevant code that this exception is occuring on.

1 solution

This is an error message dump, not a question. Do what the message says. Don't data bind in page load, do it in page prerender.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900