Hello,
I have a DropDownList for source type and a panel for displaying TreeView based on the source type.. The problem is- if i select different source type drom ddlSrcType, other than the item which was selected in the previous run the following error message is displayed.. Please help me in this regard..
Failed to load viewstate. The control tree into which viewstate is being loaded must match the control tree that was used to save viewstate during the previous request. For example, when adding controls dynamically, the controls added during a post-back must match the type and position of the controls added during the initial request.
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.Web.Http Exception: Failed to load viewstate. The control tree into which viewstate is being loaded must match the control tree that was used to save viewstate during the previous request. For example, when adding controls dynamically, the controls added during a post-back must match the type and position of the controls added during the initial request.
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:
[HttpException (0x80004005): Failed to load viewstate. The control tree into which viewstate is being loaded must match the control tree that was used to save viewstate during the previous request. For example, when adding controls dynamically, the controls added during a post-back must match the type and position of the controls added during the initial request.]
System.Web.UI.C ontrol.LoadView StateRecursive( Object savedState) +483
System.Web.UI.C ontrol.LoadChil dViewStateByInd ex(ArrayList childState) +195
System.Web.UI.C ontrol.LoadView StateRecursive( Object savedState) +424
System.Web.UI.C ontrol.LoadChil dViewStateByInd ex(ArrayList childState) +195
System.Web.UI.C ontrol.LoadView StateRecursive( Object savedState) +424
System.Web.UI.C ontrol.LoadChil dViewStateByInd ex(ArrayList childState) +195
System.Web.UI.C ontrol.LoadView StateRecursive( Object savedState) +424
System.Web.UI.C ontrol.LoadChil dViewStateByInd ex(ArrayList childState) +195
System.Web.UI.C ontrol.LoadView StateRecursive( Object savedState) +424
System.Web.UI.C ontrol.LoadChil dViewStateByInd ex(ArrayList childState) +195
System.Web.UI.C ontrol.LoadView StateRecursive( Object savedState) +424
System.Web.UI.P age.LoadAllStat e() +559
System.Web.UI.P age.ProcessRequ estMain(Boolean includeStagesBe foreAsyncPoint, Boolean includeStagesAf terAsyncPoint) +2238
Version Information: Microsoft .NET Framework Version:2.0.507 27.832; ASP.NET Version:2.0.507 27.832
Nitha
0 1650 Sign in to post your reply or Sign up for a free account.
Similar topics |
by: Eamonn O'Connell |
last post by:
Hi,
We have an ASP.net application, where we dynamically add controls, in the
Page_Load. Occasionally, when the user posts back the page (e.g. clicks Save
button on the page), we get a "Failed to load viewstate" error. This happens
on Windows Server 2003. It happens erratically, and appears to happen after
the application has been running (and in use) for some time. When the
problem arises, it appears to happen more frequently for a...
|
by: Josema |
last post by:
Hi to all,
I have a webform.aspx and inside i have a dropdown list with autopostback
and a place holder...
Depending of the selected index that the user selects in the dropdownlist i
load a usercontrol into the place holder...
i dont know why im getting this error:
|
by: John Kirksey |
last post by:
I have a page that uses an in-place editable DataGrid that supports sorting and paging. EnableViewState is turned ON. At the top of the page are several search fields that allow the user to filter the results in the grid.
Say you filter the grid for records that have a certain condition set to "NO" (in this case a checkbox). In this scenario the search returns one result. If I then check the checkbox ("YES") and save it, I now get my message...
|
by: et |
last post by:
I. Failed to load viewstate. The control tree into which
viewstate is being loaded must match the control tree that was used to save
viewstate during the previous request. For example, when adding controls
dynamically, the controls added during a post-back must match the type and
position of the controls added during the initial request.
Description: An unhandled exception occurred during the execution of the
current web...
|
by: Dhruba Bandopadhyay |
last post by:
Validation of viewstate MAC failed. If this application is hosted by a Web
Farm or cluster, ensure that <machineKey> configuration specifies the same
validationKey and validation algorithm. AutoGenerate cannot be used in a
cluster.
The above message is what I get in my ASP.NET 2.0 page. I have debugging
turned on and for those who want to see the stack trace, see below.
In my old web site I had a frame set with a ASP page in left frame...
| |
by: rockdale |
last post by:
Sometime my ASP.NET application got this error message but not always
everytime.
Failed to load viewstate. The control tree into which viewstate is
being loaded must match the control tree that was used to save
viewstate during the previous request. For example, when adding
controls dynamically, the controls added during a post-back must match
the type and position of the controls added during the initial request
|
by: sck10 |
last post by:
Hello,
I have applications that produce the following error when they have been
open to long without activity. Is there any way to force a re-load of the
page or go to another page if the page has expired instead of getting the
error?
Thanks,
|
by: sck10 |
last post by:
Hello,
I have a web page that has a GridView and a FormView, each in its own
panel. The GridView shows a list of records in a database. When a row in
the GridView is selected the FormView Panel becomes visible.
pnlGridViewSearchList
pnlFormView
The problem that I am having is that if I set the FormView Panel's
|
by: Rotsey |
last post by:
Hi,
I have a web site that uses user controls to display different formats of
timesheets.
I have a browse page that has prev/next buttons to browse through a set of
timesheets.
As I say they can be different user controls for each timesheet type.
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |