Upgrading RadFilter from Pre-2010.3.1109

4 posts, 0 answers
  1. Campus Labs
    Campus Labs avatar
    13 posts
    Member since:
    Jan 2007

    Posted 05 May 2011 Link to this post

    I have been using the 2010.1.415 release of the RadFilter for some time now. As I look to upgrade to the latest release (2011.1.413), I've run into a problem where the RadFilter cannot load a previously saved state from the database. It looks to be the same issue as detailed here - that is, as of the Q3 2010 release (2010.3.1109), there is now a new way to save state.

    I currently have customer RadFilter settings saved in a database. How can I upgrade this data to be compatible with the latest release?
  2. Veli
    Veli avatar
    2002 posts

    Posted 11 May 2011 Link to this post

    Hi Ross,

    Before version Q3 2010, RadFilter used the ObjectStateFormatter for serialization and deserialization of filter expressions. The biggest caveat to this approach was that the ObjectStateFormatter did not support deserialization of object data serialized from another assembly version. Starting with Q3 2010, RadFilter now supports a second type of serialization - through the BinaryFormatter. The BinaryFormatter has the AssemblyFormat=FormatAssemblyStyle.Simple property set, meaning it can deserialize object data from a previous assembly version. Obviously, the BinaryFormatter provides greater flexibility, but comes at a cost too - it doesn't work in a medium trust environment.

    Because the version of RadFilter (Q1 2010) you used when you serialized your settings data did not support the BinaryFormatter, you cannot deserialize this state with the latest version of the controls. The serialized data in your database is meaningful to the ObjectStateFormatter only, but the latter will fail to deserialize it with a version of RadControls different than the one you used when serializing.

    the Telerik team

    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

  3. Parimala
    Parimala avatar
    4 posts
    Member since:
    Aug 2010

    Posted 15 Jun 2012 Link to this post


    I also have the same issue , earlier I used the Q3 2010 version , now I have upgraded to 2011.3.1115.35 version. Now the binary value stored in the DB, while executing throw an error "The input stream is not a valid binary format". How to avoid this error and store the correct values to the database.

    Thanks in advance
  4. Tsvetina
    Tsvetina avatar
    2087 posts

    Posted 20 Jun 2012 Link to this post

    Hi Parimala,

    As noted by my collegue, all versions of RadFilter prior to Q3 2010 use the ObjectStateFormatter by default. Due to the nature of this formatter, it is not possible to deserialize settings, saved with different version of the assembly.
    In other words, you cannot deserialize these settings using a newer dll version but once you save new settings using the BinaryFormatter, you will not encounter this problem again. 

    Kind regards,
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Back to Top