Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / ndp / fx / src / xsp / System / Web / UI / ErrorFormatterPage.cs / 1 / ErrorFormatterPage.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * This is a page class that is used for adaptive error formatting for mobile * devices. * * NOTE: We explicitly override the state management methods because if the * normal page class is used, an exception is thrown for mobile devices. * For example, WmlPageAdapter uses SessionPageStatePersister * for persisting view state. SessionPageStatePersister requires * Context.Session to be available. Otherwise, it would throw in the * constructor. However, when an error occurred, Context.Session is * removed by SessionStateModule before the error is being formatted and * rendered. Hence the methods are overridden below and ignored to avoid * the exception since there is no need to persist any view state for the * adaptive error page which is created dynamically during error handling. * * Copyright (c) 2003 Microsoft Corporation */ namespace System.Web.UI { internal sealed class ErrorFormatterPage: Page { protected internal override void SavePageStateToPersistenceMedium(Object viewState) { // Override and ignore. No need to save view state for this page. } protected internal override Object LoadPageStateFromPersistenceMedium() { // Override and ignore. No view state to load for this page. return null; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * This is a page class that is used for adaptive error formatting for mobile * devices. * * NOTE: We explicitly override the state management methods because if the * normal page class is used, an exception is thrown for mobile devices. * For example, WmlPageAdapter uses SessionPageStatePersister * for persisting view state. SessionPageStatePersister requires * Context.Session to be available. Otherwise, it would throw in the * constructor. However, when an error occurred, Context.Session is * removed by SessionStateModule before the error is being formatted and * rendered. Hence the methods are overridden below and ignored to avoid * the exception since there is no need to persist any view state for the * adaptive error page which is created dynamically during error handling. * * Copyright (c) 2003 Microsoft Corporation */ namespace System.Web.UI { internal sealed class ErrorFormatterPage: Page { protected internal override void SavePageStateToPersistenceMedium(Object viewState) { // Override and ignore. No need to save view state for this page. } protected internal override Object LoadPageStateFromPersistenceMedium() { // Override and ignore. No view state to load for this page. return null; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- DataContractSet.cs
- DecoderFallbackWithFailureFlag.cs
- CatalogPartCollection.cs
- SemaphoreSecurity.cs
- ObjectStateEntryDbUpdatableDataRecord.cs
- Int64.cs
- StylusPointDescription.cs
- LayoutExceptionEventArgs.cs
- EntityDataSourceContainerNameItem.cs
- DataGridPageChangedEventArgs.cs
- CheckBoxList.cs
- ItemDragEvent.cs
- DynamicValueConverter.cs
- WebPageTraceListener.cs
- sqlinternaltransaction.cs
- XPathDescendantIterator.cs
- EntityViewGenerationAttribute.cs
- GenerateScriptTypeAttribute.cs
- ProfessionalColors.cs
- ExpressionPrefixAttribute.cs
- PrintPreviewDialog.cs
- TabControlCancelEvent.cs
- DocumentPaginator.cs
- BitStream.cs
- ReflectionPermission.cs
- MD5Cng.cs
- FormatSettings.cs
- SqlWebEventProvider.cs
- RangeBase.cs
- WindowsFont.cs
- basecomparevalidator.cs
- MulticastNotSupportedException.cs
- WhitespaceSignificantCollectionAttribute.cs
- SiteOfOriginContainer.cs
- TypeTypeConverter.cs
- AutomationPropertyInfo.cs
- BaseValidatorDesigner.cs
- GlobalizationSection.cs
- PluralizationService.cs
- PageRequestManager.cs
- WinInetCache.cs
- BamlLocalizer.cs
- HandlerMappingMemo.cs
- NonClientArea.cs
- RoleManagerEventArgs.cs
- ReflectionUtil.cs
- TableLayoutCellPaintEventArgs.cs
- PackUriHelper.cs
- QilFunction.cs
- SQLInt64.cs
- ListCollectionView.cs
- ParseNumbers.cs
- AmbientLight.cs
- SessionStateUtil.cs
- XmlSignificantWhitespace.cs
- CodeEventReferenceExpression.cs
- WebEventTraceProvider.cs
- GenericIdentity.cs
- XPathNodeIterator.cs
- ParserContext.cs
- ToolboxItem.cs
- XmlEventCache.cs
- RequestQueryParser.cs
- HttpCacheVaryByContentEncodings.cs
- ParseElement.cs
- ByteFacetDescriptionElement.cs
- LinkButton.cs
- URIFormatException.cs
- TreeWalker.cs
- DataControlReference.cs
- XmlQueryContext.cs
- Transform3D.cs
- HttpCapabilitiesSectionHandler.cs
- ResourceManagerWrapper.cs
- SocketPermission.cs
- CLSCompliantAttribute.cs
- BaseValidatorDesigner.cs
- SiteMapDesignerDataSourceView.cs
- BaseEntityWrapper.cs
- MimeObjectFactory.cs
- GeneralTransformGroup.cs
- ThrowOnMultipleAssignment.cs
- SystemIPAddressInformation.cs
- UnsafeNativeMethods.cs
- Validator.cs
- WebBaseEventKeyComparer.cs
- InstanceContextMode.cs
- GeneratedView.cs
- BevelBitmapEffect.cs
- ProxyHelper.cs
- RequestResizeEvent.cs
- SerialPinChanges.cs
- OutputWindow.cs
- SQLInt64Storage.cs
- TypeContext.cs
- ProfileBuildProvider.cs
- ClaimSet.cs
- EpmTargetPathSegment.cs
- AssemblyHash.cs
- WindowsFormsHostPropertyMap.cs