473,408 Members | 1,747 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

Viewstate error problem!

Hi,

I get the "Unable to validate data". It appears when I do a autopostback!
Can anybody tell me what the problem is?

Thx
Nov 19 '05 #1
2 914
This indicates the viewstate of the page posted back to the server is not
what was expected. Either the server cannot read it or it does not match up
with the controls on the page.

A few possible reasons:

If you add any controls to the page using code, on post back the controls
need to be added back to the page, the same controls need to be added back
in the exact same order. If you don't add them back or add different ones
in a different order before the viewstate is parsed you would get this
error...the viewstate hasn't changed but the controls don't match up with it
anymore.

You are viewing the page, you alter the page in your designer and upload
that change before post back.

You are using viewstateMAC, to encrypt the viewstate, and the Message
Authenication Code is reset i.e. timeout, server reset (these would
typically require you to sit on a page for quite some time), when using
server farm with the machinekey not syncronized between the servers.etc or
if you use a use Server.Transfer in the page and the MAC is not the same on
the two pages..

Another version of this message is "Viewstate is invalid for this page"
(depends on the version of .Net and what if any service pack / hotfixe you
may have installed).

"FabFreddy" <fa*******@zonnet.nl> wrote in message
news:41**************************@news.versatel.nl ...
Hi,

I get the "Unable to validate data". It appears when I do a autopostback!
Can anybody tell me what the problem is?

Thx

Nov 19 '05 #2
I am also getting the same error. I am not on a Server Farm, however, I
am using Server.Transfer taking advantage of the performance gain and
being able to add querystring values to the Context.

Doing some research, some people mentioned that if you specify the
second parameter value to Server.Transfer as true would cause this
problem to occur, however, thats not the case for me.

The wierd part is that I cannot replicate this problem on my development
box which is on a Windows XP Professional machine running IIS 5. I keep
getting this error on a Window 2003 production box.

Any help would be greatly appreciated.

*** Sent via Developersdex http://www.developersdex.com ***
Nov 19 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
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...
1
by: Ralph Soons | last post by:
Hi all, I am trying to save the viewstate in a session instead of storing it in a hidden of the webpage which is default. This because of performance reasons. When I use line 2 in combination...
2
by: Janaka | last post by:
We have managed to lock down 99% of the application errors occurring in our asp.net sites. The only errors which occur on a regular basis now are viewstate errors. We have disabled viewstate on...
11
by: Nad | last post by:
Hello, I have a page with two link buttons. When I click on the first one I call server.execute("target.aspx") to view target.aspx on the original page. Then I click on the second link button...
10
by: Robert | last post by:
I have an app that was originally 1.1, now migrated to 2.0 and have run into some sporadic viewstate errors...usually saying the viewstate is invalid, eventvalidation failed or mac error. My web...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
Oralloy
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,...
0
agi2029
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,...
0
isladogs
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...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.