Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Controls / ValidationErrorEventArgs.cs / 1305600 / 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.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- RedirectionProxy.cs
- ColorContextHelper.cs
- Timeline.cs
- ProtocolInformationReader.cs
- Cursors.cs
- mongolianshape.cs
- RichTextBox.cs
- CodeComment.cs
- RepeaterItem.cs
- TextModifier.cs
- IgnoreFileBuildProvider.cs
- BitmapCacheBrush.cs
- SafeNativeMethods.cs
- SEHException.cs
- LockRecursionException.cs
- DetailsView.cs
- Pair.cs
- DataControlLinkButton.cs
- SoapIncludeAttribute.cs
- Process.cs
- DataBoundLiteralControl.cs
- CompositeActivityCodeGenerator.cs
- XmlSerializerSection.cs
- panel.cs
- COM2ExtendedTypeConverter.cs
- XmlChildNodes.cs
- ProcessMessagesAsyncResult.cs
- ListViewCommandEventArgs.cs
- CompatibleComparer.cs
- SqlErrorCollection.cs
- WebColorConverter.cs
- EnterpriseServicesHelper.cs
- WorkflowInstanceRecord.cs
- XmlRawWriter.cs
- MasterPageCodeDomTreeGenerator.cs
- FastEncoderWindow.cs
- OdbcInfoMessageEvent.cs
- StructuredType.cs
- PageStatePersister.cs
- AsyncCodeActivityContext.cs
- Authorization.cs
- MediaPlayer.cs
- ComEventsInfo.cs
- WsatRegistrationHeader.cs
- MsmqTransportSecurity.cs
- KeyFrames.cs
- recordstatefactory.cs
- SystemUnicastIPAddressInformation.cs
- MonthChangedEventArgs.cs
- ItemTypeToolStripMenuItem.cs
- EncodingFallbackAwareXmlTextWriter.cs
- versioninfo.cs
- SiteMapPath.cs
- CommonDialog.cs
- BaseCollection.cs
- Int64AnimationUsingKeyFrames.cs
- TypeExtensionConverter.cs
- SapiInterop.cs
- SchemaNotation.cs
- XPathArrayIterator.cs
- XmlTextWriter.cs
- HttpResponse.cs
- EventLogPermissionHolder.cs
- ApplicationId.cs
- TextSelectionProcessor.cs
- DictionaryBase.cs
- RegexRunner.cs
- ConversionHelper.cs
- updateconfighost.cs
- SqlNotificationRequest.cs
- PropertyRecord.cs
- DynamicMetaObjectBinder.cs
- wgx_render.cs
- Rectangle.cs
- FixedPageStructure.cs
- SelectionRange.cs
- AnimationClock.cs
- ComponentConverter.cs
- SortDescription.cs
- ValidateNames.cs
- NetworkInformationException.cs
- PropertyAccessVisitor.cs
- DataGridViewRowErrorTextNeededEventArgs.cs
- DataTable.cs
- localization.cs
- DataGridDefaultColumnWidthTypeConverter.cs
- UTF7Encoding.cs
- NativeMethods.cs
- EdmPropertyAttribute.cs
- Add.cs
- ReadOnlyHierarchicalDataSource.cs
- ItemCollection.cs
- ProfileSettings.cs
- PromptEventArgs.cs
- CodeAssignStatement.cs
- WindowsTitleBar.cs
- KeyPullup.cs
- unsafenativemethodsother.cs
- ObjectManager.cs
- FunctionUpdateCommand.cs