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
- Avt.cs
- ZipFileInfo.cs
- DataFormats.cs
- Visual.cs
- MultiPageTextView.cs
- WebEncodingValidator.cs
- Visitors.cs
- LabelEditEvent.cs
- compensatingcollection.cs
- DropShadowEffect.cs
- InternalControlCollection.cs
- HTMLTextWriter.cs
- RtfToXamlLexer.cs
- FileDialogPermission.cs
- ProcessRequestArgs.cs
- SchemaMerger.cs
- RemotingClientProxy.cs
- BinaryEditor.cs
- PageContentCollection.cs
- XsltSettings.cs
- LayoutSettings.cs
- DisplayMemberTemplateSelector.cs
- HtmlSelect.cs
- CompositeFontFamily.cs
- LoadWorkflowByKeyAsyncResult.cs
- SudsParser.cs
- ValueExpressions.cs
- EntityCommandDefinition.cs
- NamespaceQuery.cs
- TextEditorParagraphs.cs
- SqlMethodCallConverter.cs
- BlurBitmapEffect.cs
- mongolianshape.cs
- SelectionGlyph.cs
- TranslateTransform3D.cs
- RegexCompiler.cs
- ChannelServices.cs
- CurrencyManager.cs
- ResetableIterator.cs
- EdmProviderManifest.cs
- BooleanProjectedSlot.cs
- ByeMessageCD1.cs
- Visual3D.cs
- JoinQueryOperator.cs
- WebPartZoneCollection.cs
- RequestCachingSection.cs
- ObjectConverter.cs
- EntityParameterCollection.cs
- EditorPartChrome.cs
- PathHelper.cs
- ActivityDelegate.cs
- ViewBox.cs
- HandlerBase.cs
- PeerName.cs
- ProfileInfo.cs
- Item.cs
- PromptBuilder.cs
- DataGridViewHeaderCell.cs
- COM2AboutBoxPropertyDescriptor.cs
- InheritanceUI.cs
- ReachDocumentReferenceCollectionSerializerAsync.cs
- FixedBufferAttribute.cs
- CodeTypeConstructor.cs
- XslAstAnalyzer.cs
- BasicHttpBindingElement.cs
- NumberFormatInfo.cs
- StagingAreaInputItem.cs
- Tag.cs
- XmlSchemaAttribute.cs
- XPathNodeList.cs
- EntityContainerEntitySet.cs
- CharAnimationBase.cs
- ToolStripPanel.cs
- LogReservationCollection.cs
- SequenceDesigner.cs
- AttributeXamlType.cs
- TabControlAutomationPeer.cs
- CustomLineCap.cs
- Point.cs
- ContractComponent.cs
- XhtmlBasicSelectionListAdapter.cs
- CodeDomLocalizationProvider.cs
- ExternalCalls.cs
- ListViewItemMouseHoverEvent.cs
- SqlRewriteScalarSubqueries.cs
- InitiatorSessionSymmetricMessageSecurityProtocol.cs
- DataFormats.cs
- PropertyDescriptor.cs
- TrackingServices.cs
- HttpsTransportBindingElement.cs
- FlowDocumentPaginator.cs
- ListViewUpdatedEventArgs.cs
- AudioException.cs
- ProgressBarAutomationPeer.cs
- QilXmlReader.cs
- DataControlImageButton.cs
- ResourceType.cs
- JsonFormatGeneratorStatics.cs
- Publisher.cs
- VisualStyleElement.cs