Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / wpf / src / Framework / System / Windows / Controls / ValidationErrorEventArgs.cs / 1 / ValidationErrorEventArgs.cs
//---------------------------------------------------------------------------- // //// Copyright (C) 2003 by Microsoft Corporation. All rights reserved. // // // // Description: // EventArgs for ValidationError event. // // See specs at http://avalon/connecteddata/Specs/Validation.mht // // History: // 5/13/2004 mharper: created. // //--------------------------------------------------------------------------- using System; using System.Windows; using MS.Internal; namespace System.Windows.Controls { ///Describes if a validation error has been added or cleared /// public enum ValidationErrorEventAction { ///A new ValidationError has been detected. Added, ///An existing ValidationError has been cleared. Removed, } ////// EventArgs for ValidationError event. /// public class ValidationErrorEventArgs : RoutedEventArgs { ////// Constructor /// internal ValidationErrorEventArgs(ValidationError validationError, ValidationErrorEventAction action) { Invariant.Assert(validationError != null); RoutedEvent = Validation.ErrorEvent; _validationError = validationError; _action = action; } ////// The ValidationError that caused this ValidationErrorEvent to /// be raised. /// public ValidationError Error { get { return _validationError; } } ////// Action indicates whether the public ValidationErrorEventAction Action { get { return _action; } } ///is a new error /// or a previous error that has now been cleared. /// /// The mechanism used to call the type-specific handler on the /// target. /// /// /// The generic handler to call in a type-specific way. /// /// /// The target to call the handler on. /// protected override void InvokeEventHandler(Delegate genericHandler, object genericTarget) { EventHandlerhandler = (EventHandler ) genericHandler; handler(genericTarget, this); } private ValidationError _validationError; private ValidationErrorEventAction _action; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // // // Copyright (C) 2003 by Microsoft Corporation. All rights reserved. // // // // Description: // EventArgs for ValidationError event. // // See specs at http://avalon/connecteddata/Specs/Validation.mht // // History: // 5/13/2004 mharper: created. // //--------------------------------------------------------------------------- using System; using System.Windows; using MS.Internal; namespace System.Windows.Controls { ///Describes if a validation error has been added or cleared /// public enum ValidationErrorEventAction { ///A new ValidationError has been detected. Added, ///An existing ValidationError has been cleared. Removed, } ////// EventArgs for ValidationError event. /// public class ValidationErrorEventArgs : RoutedEventArgs { ////// Constructor /// internal ValidationErrorEventArgs(ValidationError validationError, ValidationErrorEventAction action) { Invariant.Assert(validationError != null); RoutedEvent = Validation.ErrorEvent; _validationError = validationError; _action = action; } ////// The ValidationError that caused this ValidationErrorEvent to /// be raised. /// public ValidationError Error { get { return _validationError; } } ////// Action indicates whether the public ValidationErrorEventAction Action { get { return _action; } } ///is a new error /// or a previous error that has now been cleared. /// /// The mechanism used to call the type-specific handler on the /// target. /// /// /// The generic handler to call in a type-specific way. /// /// /// The target to call the handler on. /// protected override void InvokeEventHandler(Delegate genericHandler, object genericTarget) { EventHandlerhandler = (EventHandler ) genericHandler; handler(genericTarget, this); } private ValidationError _validationError; private ValidationErrorEventAction _action; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- XmlDataCollection.cs
- CachedPathData.cs
- Size3D.cs
- SqlHelper.cs
- DayRenderEvent.cs
- Int64Animation.cs
- Vector3DConverter.cs
- ProfileSection.cs
- ExpressionPrinter.cs
- WebDisplayNameAttribute.cs
- StatusBarPanelClickEvent.cs
- AutomationPeer.cs
- TypeConverterValueSerializer.cs
- BaseValidatorDesigner.cs
- ToolstripProfessionalRenderer.cs
- MenuTracker.cs
- KeyMatchBuilder.cs
- InvalidStoreProtectionKeyException.cs
- XamlReader.cs
- SecurityVerifiedMessage.cs
- ValueChangedEventManager.cs
- WorkflowIdleBehavior.cs
- DesignerTextBoxAdapter.cs
- XmlWrappingReader.cs
- LinkArea.cs
- ImageIndexConverter.cs
- RegexStringValidatorAttribute.cs
- SerializationInfoEnumerator.cs
- RectAnimationClockResource.cs
- ScriptRegistrationManager.cs
- PropertyEntry.cs
- codemethodreferenceexpression.cs
- base64Transforms.cs
- MailAddress.cs
- WsdlInspector.cs
- InfoCardProofToken.cs
- DiscoveryDocumentSerializer.cs
- OleDbDataAdapter.cs
- ConstraintManager.cs
- WSTransactionSection.cs
- ExpressionPrefixAttribute.cs
- DependentList.cs
- InitializationEventAttribute.cs
- Bidi.cs
- SecurityPolicySection.cs
- WebPartConnectionsCancelVerb.cs
- DiagnosticsConfiguration.cs
- UnsafeNativeMethodsTablet.cs
- AstTree.cs
- UiaCoreApi.cs
- BaseResourcesBuildProvider.cs
- DataGridViewComboBoxColumn.cs
- SerializationAttributes.cs
- EventData.cs
- Vector.cs
- MultipartContentParser.cs
- ChildTable.cs
- WebControlAdapter.cs
- PermissionAttributes.cs
- AndMessageFilterTable.cs
- SafeRightsManagementHandle.cs
- PageBreakRecord.cs
- OSFeature.cs
- ResXBuildProvider.cs
- StatusBarPanelClickEvent.cs
- PaginationProgressEventArgs.cs
- ListChangedEventArgs.cs
- SchemaElementDecl.cs
- Timeline.cs
- Assert.cs
- Relationship.cs
- WorkItem.cs
- ThemeInfoAttribute.cs
- ZipArchive.cs
- InputBindingCollection.cs
- ClientUrlResolverWrapper.cs
- FunctionParameter.cs
- ProviderCommandInfoUtils.cs
- OutputScopeManager.cs
- ConnectionsZoneDesigner.cs
- TraceListener.cs
- GeneralTransform3DGroup.cs
- ModuleElement.cs
- ToolStripContentPanelDesigner.cs
- LifetimeServices.cs
- ConstraintConverter.cs
- KeyEvent.cs
- MonthCalendar.cs
- AssemblyResourceLoader.cs
- Attribute.cs
- MetaModel.cs
- PropertyTab.cs
- shaperfactory.cs
- GridViewRowPresenterBase.cs
- LinqDataSourceDeleteEventArgs.cs
- Selector.cs
- TextRangeAdaptor.cs
- RegexNode.cs
- InteropAutomationProvider.cs
- BindingMAnagerBase.cs