This is a migrated thread and some comments may be shown as answers.

ViewState lost when using RadSessionPageStateCompression

6 Answers 147 Views
Compression
This is a migrated thread and some comments may be shown as answers.
Alexander
Top achievements
Rank 1
Alexander asked on 24 Oct 2011, 08:40 AM
We have an ASP.NET 4 web app and we are using RadSessionPageStateCompression by configuring it in the BrowserFile.browser file like this:

<browsers>
  <browser refID="Default">
    <controlAdapters>
      <adapter controlType="System.Web.UI.Page" adapterType="Telerik.Web.UI.RadSessionPageStateCompression, Telerik.Web.UI, Version=2011.2.712.40, Culture=neutral, PublicKeyToken=121fae78165ba3d4" />
    </controlAdapters>
  </browser>
</browsers> When working in just one tab in the browser ViewState is OK. When working in several tabs (IE 8/9, Chrome 14.x) part of the ViewState is lost. Can you advice what is wrong? Regards, alexander

6 Answers, 1 is accepted

Sort by
0
Veli
Telerik team
answered on 26 Oct 2011, 07:45 AM
Hello Alexander,

How do you identify part of the ViewState is lost? Are you getting ViewState deserialization exceptions of some sort, or the data in your ViewState is lost? If you are getting any errors, can you, please, post the error message and stack trace, so that we can try to identify what's causing the issue. Also, are you getting this in development, or when running on production environment. If the latter, are you, by any chance, using any webfarm / load-balancing scenarios with multiple nodes?

Any further info you believe might be helpful is appreciated.

Greetings,
Veli
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
0
Alexander
Top achievements
Rank 1
answered on 26 Oct 2011, 08:04 AM
Hi,

Just data stored in the ViewState is lost. See example:

1. Tab1 - during initial load of the page (not post back) we execute ViewState["text"] = "Hello World";
2. Open new Tab2 and perform some actions, go to other web pages...
3. Go back to Tab1 and click a button -> perform postback. When checking ViewState["text"], it returns null instead of "Hello World"

This can be reproduced in ASP.NET Development Server as well in IIS 6.0 production environment (no web farm or other NLB scenario).

Regards,

Alexander
0
Veli
Telerik team
answered on 26 Oct 2011, 09:49 AM
Hi Alexander,

I tried to reproduce the scenario you are describing in a test project but I couldn't succeed. I am attaching the test project. Can you, please, run it locally on your side and try to reproduce this issue in it. Let me know of the exact steps you took so that we can try it locally too.

Veli
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
0
Alexander
Top achievements
Rank 1
answered on 26 Oct 2011, 12:35 PM
Hi,

By using two different tabs I meant browser tabs, not the telerik:RadTab control as you have included in your example.

Regards,

Alexander

 
0
Veli
Telerik team
answered on 26 Oct 2011, 01:33 PM
Hi Alexander,

Thanks for clarifying. In any case, we are not able to reproduce this issue locally. If the issue persists, consider opening a regular support ticket where you can send us some test project we can debug locally. At this point, we need to be able to reproduce this issue on our side to advise  you further.

Veli
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
0
David
Top achievements
Rank 1
answered on 11 Oct 2012, 10:43 AM
RadSessionPageStateCompression is a implementation of SessionStatePagePersister which does not work properly across multiple tabs because uses a queue of state on witch they get lost after few postbacks. You could switch to HiddenFieldPageStateCompression or re size on web config section system.web  sessionPageState the historySize.


Tags
Compression
Asked by
Alexander
Top achievements
Rank 1
Answers by
Veli
Telerik team
Alexander
Top achievements
Rank 1
David
Top achievements
Rank 1
Share this question
or