How to stop asp.net from trying to load sharepoint? - asp.net

I have a ASP.net forms page that is acting as a proxy.
My website is downloading some content from another website, companyX.com.
companyX.com's site is using sharePoint.
My site is downloading the HTML from companyX.com and successfully adding it to my page, however, after Page_Init, Page_Load and Page_Unload but before Render my page is throwing the error pasted below.
My site does not have any sharepoint installed. However, it looks like there is something in asp.net that is processing the HTML content in my page, recognizing some sharepoint tags and then trying to load sharepoint. I would love to turn this off!
My page does have EnableViewState="false" EnableViewStateMac="false" ValidateRequest="false"
Error:
System.Web.HttpException (0x80004005): The state information is invalid for this page and might be corrupted. ---> System.Web.UI.ViewStateException: Invalid viewstate.
Client IP: 127.0.0.1
Port: 55413
Referer: xxx/App.aspx?id=xxx
Path: /App.aspx
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.72 Safari/537.36
ViewState: xxx... ---> System.ArgumentException: The serialized data is invalid. ---> System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' or one of its dependencies. The system cannot find the file specified.
at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMarkHandle stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName, ObjectHandleOnStack type)
at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName)
at System.RuntimeType.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark)
at System.Type.GetType(String typeName, Boolean throwOnError)
at System.Web.UI.ObjectStateFormatter.DeserializeType(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader)
at System.Web.UI.ObjectStateFormatter.Deserialize(Stream inputStream)
--- End of inner exception stack trace ---
at System.Web.UI.ObjectStateFormatter.Deserialize(Stream inputStream)
at System.Web.UI.ObjectStateFormatter.Deserialize(String inputString, Purpose purpose)
at System.Web.UI.ObjectStateFormatter.System.Web.UI.IStateFormatter2.Deserialize(String serializedState, Purpose purpose)
at System.Web.UI.Util.DeserializeWithAssert(IStateFormatter2 formatter, String serializedState, Purpose purpose)
at System.Web.UI.HiddenFieldPageStatePersister.Load()
--- End of inner exception stack trace ---
at System.Web.UI.ViewStateException.ThrowError(Exception inner, String persistedState, String errorPageMessage, Boolean macValidationError)
at System.Web.UI.HiddenFieldPageStatePersister.Load()
at System.Web.UI.Page.LoadPageStateFromPersistenceMedium()
at System.Web.UI.Page.LoadAllState()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest()
at System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context)
at System.Web.UI.Page.ProcessRequest(HttpContext context)
at ASP.app_aspx.ProcessRequest(HttpContext context)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

ASP.net isn't tying to load Sharepoint, it's trying to make sense of the ViewState contained in the page you are retrieving but cannot because it is built by another server with a different machine key et al.
I would personally remove the ViewState hidden field from the retrieved HTML prior to the Render stage, otherwise you might have ongoing issues that may confuse matters on a random basis.

I finally finally fixed it by adding the following to my page:
Protected Overrides Function LoadPageStateFromPersistenceMedium() As Object
Return Nothing
End Function

Related

Asp.Net webforms Viewstate validation getting failed

I have a website hosted on shared server, running on .Net version : 4.0.30319.34280
I was initially getting the following error
Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster.
In order to fix it I added a section in my web.config, by following the steps mentioned at : https://support.microsoft.com/en-us/kb/312906
Now I am getting the following error
Unable to validate data.
stack trace:
[HttpException (0x80004005): Unable to validate data.]
System.Web.Configuration.MachineKeySection.EncryptOrDecryptData(Boolean fEncrypt, Byte[] buf, Byte[] modifier, Int32 start, Int32 length, Boolean useValidationSymAlgo, Boolean useLegacyMode, IVType ivType, Boolean signData) +1072
System.Web.UI.Page.EncryptString(String s, Purpose purpose) +150
System.Web.Handlers.AssemblyResourceLoader.FormatWebResourceUrl(String assemblyName, String resourceName, Int64 assemblyDate, Boolean htmlEncoded) +52
System.Web.Handlers.AssemblyResourceLoader.GetWebResourceUrlInternal(Assembly assembly, String resourceName, Boolean htmlEncoded, Boolean forSubstitution, IScriptManager scriptManager, Boolean enableCdn) +662
System.Web.Handlers.AssemblyResourceLoader.GetWebResourceUrl(Type type, String resourceName, Boolean htmlEncoded, IScriptManager scriptManager, Boolean enableCdn) +188
System.Web.UI.ClientScriptManager.GetWebResourceUrl(Page owner, Type type, String resourceName, Boolean htmlEncoded, IScriptManager scriptManager, Boolean enableCdn) +99
System.Web.UI.ClientScriptManager.RegisterClientScriptResource(Type type, String resourceName) +96
System.Web.UI.WebControls.BaseValidator.RegisterValidatorCommonScript() +212
System.Web.UI.WebControls.BaseValidator.OnPreRender(EventArgs e) +85
System.Web.UI.Control.PreRenderRecursiveInternal() +88
System.Web.UI.Control.PreRenderRecursiveInternal() +160
System.Web.UI.Control.PreRenderRecursiveInternal() +160
System.Web.UI.Control.PreRenderRecursiveInternal() +160
System.Web.UI.Control.PreRenderRecursiveInternal() +160
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +883
Any help in solving would be appreciated.
It could be that IIS recycled your app and therefore you get new keys for the session/view state. To alleviate this, add a machine static key in the web.config.
<machineKey
validationKey="56AB7132992003EE87F74AE4D9675D65EED8018D3528C0B8874905B51940DEAF6B85F1D922D19AB8F69781B2326A2F978A064708822FD8C54ED74CADF8592E17"
decryptionKey="A69D80B92A16DFE1698DFE86D4CED630FA56D7C1661C8D05744449889B88E8DC"
validation="SHA1" decryption="AES" />
Refrence Link

Parsing property in ASP version 4 causes FormatException

I have this code fragment
public Version BuildVersion =Version.Parse(System.Web.Configuration.WebConfigurationManager.AppSettings["BuildVersion"].ToString());
which reads following appSetting entry
<appSettings>
<add key="BuildVersion" value="4.7.2.2" />
</appSettings>
This throws exception
[FormatException: Input string was not in a correct format.]
System.VersionResult.SetFailure(ParseFailureKind failure, String argument) +10852983
System.Version.TryParseComponent(String component, String componentName, VersionResult& result, Int32& parsedComponent) +105
System.Version.TryParseVersion(String version, VersionResult& result) +135
System.Version.Parse(String input) +68
QuickPick.Main..ctor() in D:\IWROX-DEV\Expresslane\IWorx-Trunk-PromoFrontEnd\ExpressLane.Web\Main.Master.cs:52
ASP.main_master..ctor() in c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\e43b3107\2f748eb6\App_Web_main.master.cdcab7d2.uaxqveln.0.cs:0
__ASP.FastObjectFactory_app_web_main_master_cdcab7d2_uaxqveln.Create_ASP_main_master() in c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\e43b3107\2f748eb6\App_Web_main.master.cdcab7d2.uaxqveln.1.cs:0
System.Web.Compilation.BuildResultCompiledType.CreateInstance() +30
System.Web.UI.MasterPage.CreateMaster(TemplateControl owner, HttpContext context, VirtualPath masterPageFile, IDictionary contentTemplateCollection) +782
System.Web.UI.Page.get_Master() +54
System.Web.UI.Page.ApplyMasterPage() +14
System.Web.UI.Page.PerformPreInit() +45
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +335
once deployed to the server, However it runs fine on VS2010 web host (ASP NET Development Server).
Most likely the correct config file is not deployed to your host.

asp.net URL Rewriting error

Could not load file or assembly 'UrlRewritingNet.UrlRewriter' or one of its dependencies. The system cannot find the file specified.
we installed the url rewriting
tried it on a website
tried it on a virtual directory
same error :/
any ideas?
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.IO.FileNotFoundException: Could not load file or assembly 'UrlRewritingNet.UrlRewriter' or one of its dependencies. The system cannot find the file specified.
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.
Assembly Load Trace: The following information can be helpful to determine why the assembly 'UrlRewritingNet.UrlRewriter' could not be loaded.
WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].
Stack Trace:
[FileNotFoundException: Could not load file or assembly 'UrlRewritingNet.UrlRewriter' or one of its dependencies. The system cannot find the file specified.]
System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMarkHandle stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName, ObjectHandleOnStack type) +0
System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName) +153
System.Type.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase) +63
System.Web.Compilation.BuildManager.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase) +124
System.Web.Configuration.ConfigUtil.GetType(String typeName, String propertyName, ConfigurationElement configElement, XmlNode node, Boolean checkAptcaBit, Boolean ignoreCase) +76
[ConfigurationErrorsException: Could not load file or assembly 'UrlRewritingNet.UrlRewriter' or one of its dependencies. The system cannot find the file specified.]
System.Web.Configuration.ConfigUtil.GetType(String typeName, String propertyName, ConfigurationElement configElement, XmlNode node, Boolean checkAptcaBit, Boolean ignoreCase) +12773840
System.Web.Configuration.Common.ModulesEntry.SecureGetType(String typeName, String propertyName, ConfigurationElement configElement) +69
System.Web.Configuration.Common.ModulesEntry..ctor(String name, String typeName, String propertyName, ConfigurationElement configElement) +66
System.Web.HttpApplication.BuildIntegratedModuleCollection(List`1 moduleList) +300
System.Web.HttpApplication.GetModuleCollection(IntPtr appContext) +1262
System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr appContext, HttpContext context, MethodInfo[] handlers) +133
System.Web.HttpApplication.InitSpecial(HttpApplicationState state, MethodInfo[] handlers, IntPtr appContext, HttpContext context) +304
System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) +404
System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) +475
[HttpException (0x80004005): Could not load file or assembly 'UrlRewritingNet.UrlRewriter' or one of its dependencies. The system cannot find the file specified.]
System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +12966756
System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +159
System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +12806561
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.18408
Just copy the UrlRewritingNet.UrlRewriter.dll and paste it in both parent and child's bin folder .. it might be not present in the child bin folder
Kindly change you application pool setting of sub web site.
to different app. pool framework.

Could not load file or assembly 'EPiServer.Framework'

Im getting this exception when configuring EPi CMS 5 to run under IIS7.5.
Exception Details: System.IO.FileNotFoundException: Could not load
file or assembly 'EPiServer.Framework' or one of its dependencies.
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.
Assembly Load Trace: The following information can be helpful to determine why the assembly 'EPiServer.Framework' could not be loaded.
WRN: Assembly binding logging is turned OFF. To enable assembly bind failure logging, set the registry value
[HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1. Note: There
is some performance penalty associated with assembly bind failure
logging. To turn this feature off, remove the registry value
[HKLM\Software\Microsoft\Fusion!EnableLog].
Stack Trace:
[FileNotFoundException: Could not load file or assembly 'EPiServer.Framework' or one of its dependencies. Det går inte att
hitta filen.] System.RuntimeTypeHandle.GetTypeByName(String name,
Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly,
StackCrawlMarkHandle stackMark, Boolean loadTypeFromPartialName,
ObjectHandleOnStack type) +0
System.RuntimeTypeHandle.GetTypeByName(String name, Boolean
throwOnError, Boolean ignoreCase, Boolean reflectionOnly,
StackCrawlMark& stackMark, Boolean loadTypeFromPartialName) +95
System.RuntimeType.GetType(String typeName, Boolean throwOnError,
Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark)
+54 System.Type.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase) +65
System.Web.Compilation.BuildManager.GetType(String typeName, Boolean
throwOnError, Boolean ignoreCase) +69
System.Web.Configuration.ConfigUtil.GetType(String typeName, String
propertyName, ConfigurationElement configElement, XmlNode node,
Boolean checkAptcaBit, Boolean ignoreCase) +52
[ConfigurationErrorsException: Could not load file or assembly 'EPiServer.Framework' or one of its dependencies. Det går inte att
hitta filen.] System.Web.Configuration.ConfigUtil.GetType(String
typeName, String propertyName, ConfigurationElement configElement,
XmlNode node, Boolean checkAptcaBit, Boolean ignoreCase) +360
System.Web.Configuration.ConfigUtil.GetType(String typeName, String
propertyName, ConfigurationElement configElement, Boolean
checkAptcaBit) +27
System.Web.Configuration.Common.ModulesEntry.SecureGetType(String
typeName, String propertyName, ConfigurationElement configElement) +44
System.Web.Configuration.Common.ModulesEntry..ctor(String name, String
typeName, String propertyName, ConfigurationElement configElement) +52
System.Web.HttpApplication.BuildIntegratedModuleCollection(List`1
moduleList) +200
System.Web.HttpApplication.GetModuleCollection(IntPtr appContext)
+1365 System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr
appContext, HttpContext context, MethodInfo[] handlers) +95
System.Web.HttpApplication.InitSpecial(HttpApplicationState state,
MethodInfo[] handlers, IntPtr appContext, HttpContext context) +194
System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr
appContext, HttpContext context) +339
System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr
appContext) +253
[HttpException (0x80004005): Could not load file or assembly 'EPiServer.Framework' or one of its dependencies. Det går inte att
hitta filen.] System.Web.HttpRuntime.FirstRequestInit(HttpContext
context) +9080108
System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +97
System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest
wr, HttpContext context) +256
Check the /Bin folder of your application and see if the EPiServer.Framework DLL is there. If it isn't you can set the DLL to "Copy Local" by right clicking on it in the References folder within Solution Explorer and selecting Properties, then set Copy Local to "true". Now when you build the solution, the DLL will be copied from it's reference location into the Bin folder. You may need to do this for all the EPiServer DLLs.
I've experienced this in the past and even when "Specific Version" is enabled there are still issue loading the correct DLLs. One way we solved it was to copy all the EPiServer DLLs into a Lib folder in our solution directory and add the references to those DLLs, keeping Specific Version and Copy Local set to true.

ViewState issue

We are using our website on Windows server 2003 with IIS 6 and also have a test server 2003 with IIS 5.
When I tested the page with ViewState on test server, it worked fine. But we tested on other server which is running IIS 6.It gave error. I compared web configuratioin file, it looked the same. There was the machine key and maximum length for view state. I've been spending couple days and still don't find it. Somebody can help me.
This error doesn't happen all the time. So I think the source code is not the problem.
Here is my error
[SerializationException: Member '_name' was not found.]
System.Runtime.Serialization.SerializationInfo.GetElement(String name, Type& foundType) +7608149
System.Runtime.Serialization.SerializationInfo.GetString(String name) +24
SD.LLBLGen.Pro.ORMSupportClasses.EntityBase2..ctor(SerializationInfo info, StreamingContext context) +69
PV.Data.Standard.EntityClasses.ClinicEntity..ctor(SerializationInfo info, StreamingContext context) +26
[TargetInvocationException: Exception has been thrown by the target of an invocation.]
System.RuntimeMethodHandle._SerializationInvoke(Object target, SignatureStruct& declaringTypeSig, SerializationInfo info, StreamingContext context) +0
System.Reflection.RuntimeConstructorInfo.SerializationInvoke(Object target, SerializationInfo info, StreamingContext context) +108
System.Runtime.Serialization.ObjectManager.CompleteISerializableObject(Object obj, SerializationInfo info, StreamingContext context) +273
System.Runtime.Serialization.ObjectManager.FixupSpecialObject(ObjectHolder holder) +49
System.Runtime.Serialization.ObjectManager.DoFixups() +223
System.Runtime.Serialization.Formatters.Binary.ObjectReader.Deserialize(HeaderHandler handler, __BinaryParser serParser, Boolean fCheck, Boolean isCrossAppDomain, IMethodCallMessage methodCallMessage) +188
System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Deserialize(Stream serializationStream, HeaderHandler handler, Boolean fCheck, Boolean isCrossAppDomain, IMethodCallMessage methodCallMessage) +203
System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Deserialize(Stream serializationStream) +12
System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader) +968
System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader) +291
System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader) +392
System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader) +404
System.Web.UI.ObjectStateFormatter.DeserializeValue(SerializerBinaryReader reader) +392
System.Web.UI.ObjectStateFormatter.Deserialize(Stream inputStream) +135
[ArgumentException: The serialized data is invalid.]
System.Web.UI.ObjectStateFormatter.Deserialize(Stream inputStream) +199
System.Web.UI.ObjectStateFormatter.Deserialize(String inputString) +297
System.Web.UI.ObjectStateFormatter.System.Web.UI.IStateFormatter.Deserialize(String serializedState) +4
System.Web.UI.Util.DeserializeWithAssert(IStateFormatter formatter, String serializedState) +37
System.Web.UI.HiddenFieldPageStatePersister.Load() +113
[ViewStateException: Invalid viewstate.
Client IP: 10.0.51.92
Port: 51267
User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/5.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; BRI/1)
ViewState: /wEPDwUJODUyMDU5NzIxDxYOHgpQcmFjdGljZVBrKClYU3lzdGVtLkd1aWQsIG1zY29ybGliLCBWZXJzaW9uPTIuMC4wLjAsIEN1bHR1cmU9bmV1dHJhbCwgUHVibGljS2V5VG9rZW49Yjc3YTVjNTYxOTM0ZTA4OSRlMzE4OTAzNy0xOWY3LWRmMTEtOGQwNC0wMDFlMGI2ZTE4MWEeCENsaW5pY1BrKCsEJGQyYzg3OWI4LTE5ZjctZGYxMS04ZDA0LTAwMWUwYjZlMTgxYR4IUHJhY3RpY2UFBFBDTFAeBkNsaW5pYwUKVy4gUk9CSU5TTx4M..]
[HttpException (0x80004005): The state information is invalid for this page and might be corrupted.]
System.Web.UI.ViewStateException.ThrowError(Exception inner, String persistedState, String errorPageMessage, Boolean macValidationError) +106
System.Web.UI.ViewStateException.ThrowViewStateError(Exception inner, String persistedState) +14
System.Web.UI.HiddenFieldPageStatePersister.Load() +217
System.Web.UI.Page.LoadPageStateFromPersistenceMedium() +105
System.Web.UI.Page.LoadAllState() +43
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +6785
System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +242
System.Web.UI.Page.ProcessRequest() +80
System.Web.UI.Page.ProcessRequestWithNoAssert(HttpContext context) +21
System.Web.UI.Page.ProcessRequest(HttpContext context) +49
ASP.clinicinfo_aspx.ProcessRequest(HttpContext context) in c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\root\9ca5f508\2be4cd8e\App_Web_sqt6xlmv.2.cs:0
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +181
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +75
I guess it's too obvious to say that your test server might serve it's purpose better if it ran on the same version of windows and IIS that your production server uses... (so that's actually one suggestion...)
Otherwise, without digging into all of the possible issues that could be causing this, you can use IIS5 compatibility mode in IIS6.
R-click your website in IIS Manager
Service
check-mark the IIS 5 Isolation mode checkbox
Has the SD.LLBLGen.Pro.ORMSupportClasses.EntityBase2 class ever had a member named _name? Is there load balancing involved here?
It looks like the ViewState was created on a machine where the SD.LLBLGen.Pro.ORMSupportClasses.EntityBase2 class had a _name_ member, and then the ViewState is being interpreted on a machine where that class does not have a_name` member.

Resources