Web site -> Web Application; can't deserialize blob

Last post 05-12-2008 8:30 PM by chowbang. 0 replies.

Sort Posts:

  • Web site -> Web Application; can't deserialize blob

    05-12-2008, 8:30 PM
    • Loading...
    • chowbang
    • Joined on 03-09-2003, 12:20 AM
    • Posts 3

    Hi, I'm having a problem similar to the last few posts of this thread: http://forums.asp.net/t/940269.aspx?PageIndex=2.

    A deserialization error occurred inside of ObjectStateFormatter. A property was typed as Type but the Type instance could not be created for 'Surfer.SurferWebPartManager, App_Code.nsz5wuot, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'.

    Before, everything was in App_Code, so it gets compiled on the fly. Now, it's in a web application project, so it gets compiled into a dll. And I guess that's why it can't find the type when deserializing the page blob. The weird thing is that it only happens on some of the pages - I'm not sure of the pattern.

    The pages are already in production, so I can't tell people to recreate the pages. Is there anything I can do without resorting back to App_Code?

    A crazy idea I had was to maybe parse the blob and use it to:

    A) Override LoadPersonalizationBlobs(), catch any deserialization errors, and programmatically "place" all the controls in the right zones to basically recontruct the page.

    B) Have a migration tool scan the db; if it detects this old signature (App_Code.nsz5wuot...), "inject" the correct one and save it back to the DB.

    Anyone have any ideas? Thanks.

Page 1 of 1 (1 items)