Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / 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
- RedirectionProxy.cs
- CodeConstructor.cs
- BaseTemplateBuildProvider.cs
- SelectedGridItemChangedEvent.cs
- Rotation3DAnimationUsingKeyFrames.cs
- ChildTable.cs
- SQLInt32.cs
- Deflater.cs
- SqlDataSourceStatusEventArgs.cs
- EpmCustomContentDeSerializer.cs
- ListControl.cs
- Certificate.cs
- TraceUtility.cs
- WebResponse.cs
- ExpressionCopier.cs
- elementinformation.cs
- Tool.cs
- SecurityUtils.cs
- XsltException.cs
- PreviewControlDesigner.cs
- DataGridViewButtonColumn.cs
- BaseAsyncResult.cs
- WebPartDisplayMode.cs
- DebugView.cs
- Bitmap.cs
- ProfileService.cs
- MdImport.cs
- ObjectFactoryCodeDomTreeGenerator.cs
- SynchronizedInputProviderWrapper.cs
- MeasureItemEvent.cs
- MLangCodePageEncoding.cs
- ReflectEventDescriptor.cs
- EntityStoreSchemaFilterEntry.cs
- ProfileManager.cs
- IconEditor.cs
- LocationReference.cs
- activationcontext.cs
- MulticastNotSupportedException.cs
- BindingSource.cs
- HttpRuntimeSection.cs
- StylusPlugin.cs
- ItemsPanelTemplate.cs
- DynamicRenderer.cs
- GorillaCodec.cs
- KeyValuePair.cs
- GridViewColumnHeaderAutomationPeer.cs
- TextPenaltyModule.cs
- CodeNamespaceCollection.cs
- LineMetrics.cs
- CustomAttributeSerializer.cs
- RegisterInfo.cs
- RegistryPermission.cs
- MimePart.cs
- CultureMapper.cs
- ControlAdapter.cs
- Geometry3D.cs
- Normalization.cs
- RegistryKey.cs
- SQLMoney.cs
- OpenTypeMethods.cs
- COM2IProvidePropertyBuilderHandler.cs
- DataGridViewRowHeaderCell.cs
- StringHelper.cs
- ObjectDataSourceMethodEventArgs.cs
- VectorAnimation.cs
- XmlNodeChangedEventArgs.cs
- RoutedEventHandlerInfo.cs
- TimeSpan.cs
- SymbolType.cs
- DifferencingCollection.cs
- JumpPath.cs
- ToolStripDropDownMenu.cs
- RepeaterItemCollection.cs
- TemplateBindingExtensionConverter.cs
- HttpRuntime.cs
- ListControlConvertEventArgs.cs
- BitmapScalingModeValidation.cs
- StreamResourceInfo.cs
- StorageModelBuildProvider.cs
- TimeSpanMinutesConverter.cs
- MembershipPasswordException.cs
- validation.cs
- FileDialogPermission.cs
- DoubleLink.cs
- DataServiceResponse.cs
- TimersDescriptionAttribute.cs
- RegexBoyerMoore.cs
- WindowsTab.cs
- Executor.cs
- ConfigurationException.cs
- UriSection.cs
- JsonFormatReaderGenerator.cs
- RuleProcessor.cs
- WindowsFormsLinkLabel.cs
- SendKeys.cs
- DataGridCellsPresenter.cs
- _ConnectionGroup.cs
- WebHostUnsafeNativeMethods.cs
- FigureParagraph.cs
- HttpValueCollection.cs