Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Framework / System / Windows / DialogResultConverter.cs / 1 / DialogResultConverter.cs
//---------------------------------------------------------------------------- // // Copyright (C) Microsoft Corporation. All rights reserved. // // File: DialogResultConverter.cs // // Description: Contains the DialogResultConverter: TypeConverter for the DialogResult class. // // History: // 10/31/2003 : [....] - Created // //--------------------------------------------------------------------------- using System; using System.ComponentModel; using System.Globalization; namespace System.Windows { ////// DialogResultConverter - Converter class for converting instances of other types to and from DialogResult instances. /// public class DialogResultConverter: TypeConverter { //------------------------------------------------------------------- // // Public Methods // //------------------------------------------------------------------- #region Public Methods ////// CanConvertFrom - We don't support convert from other types to DialogResult /// ////// bool - Always return False /// public override bool CanConvertFrom(ITypeDescriptorContext typeDescriptorContext, Type sourceType) { // We don't support ConvertFrom return false; } ////// CanConvertTo - Returns whether or not this class can convert to a given type. /// ////// bool - Always return False /// public override bool CanConvertTo(ITypeDescriptorContext typeDescriptorContext, Type destinationType) { // We don't support ConvertTo return false; } ////// ConvertFrom - Attempt to convert to a DialogResult from the given object. /// Always throw InvalidOperation exception /// public override object ConvertFrom(ITypeDescriptorContext typeDescriptorContext, CultureInfo cultureInfo, object source) { throw new InvalidOperationException(SR.Get(SRID.CantSetInMarkup)); } ////// ConvertTo - Attempt to convert a DialogResult to the given type /// Always throw InvalidOperation exception /// public override object ConvertTo(ITypeDescriptorContext typeDescriptorContext, CultureInfo cultureInfo, object value, Type destinationType) { throw new InvalidOperationException(SR.Get(SRID.CantSetInMarkup)); } #endregion } } // 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
- EdmTypeAttribute.cs
- OracleMonthSpan.cs
- EdmScalarPropertyAttribute.cs
- ToolStripComboBox.cs
- CatalogZone.cs
- DrawingAttributeSerializer.cs
- XmlSerializationGeneratedCode.cs
- CatalogZoneAutoFormat.cs
- DoWhileDesigner.xaml.cs
- COM2PictureConverter.cs
- MappedMetaModel.cs
- CodeAttributeArgumentCollection.cs
- EntityRecordInfo.cs
- AliasGenerator.cs
- Dictionary.cs
- Transform3DCollection.cs
- MSG.cs
- EntityObject.cs
- COM2ExtendedUITypeEditor.cs
- RegexGroupCollection.cs
- XsltInput.cs
- XsltLoader.cs
- SqlRowUpdatedEvent.cs
- EmptyStringExpandableObjectConverter.cs
- CompareValidator.cs
- XmlAttributeOverrides.cs
- TextParagraphView.cs
- WindowCollection.cs
- TaiwanCalendar.cs
- COM2EnumConverter.cs
- NodeFunctions.cs
- AssemblyNameProxy.cs
- CodeLabeledStatement.cs
- ValuePatternIdentifiers.cs
- PipeConnection.cs
- IISUnsafeMethods.cs
- ApplicationServiceHelper.cs
- ListBoxItemAutomationPeer.cs
- WriteTimeStream.cs
- AnchoredBlock.cs
- ELinqQueryState.cs
- RegistryKey.cs
- CompiledRegexRunnerFactory.cs
- PerfCounters.cs
- WebPartMovingEventArgs.cs
- MenuAdapter.cs
- RuntimeConfig.cs
- PartitionedStream.cs
- FacetEnabledSchemaElement.cs
- BindingGroup.cs
- AggregateNode.cs
- MessageSmuggler.cs
- ObjectReaderCompiler.cs
- Translator.cs
- SizeKeyFrameCollection.cs
- DocumentPageTextView.cs
- Run.cs
- Subtree.cs
- ColorDialog.cs
- CompositeCollection.cs
- PersonalizationEntry.cs
- ExpandedWrapper.cs
- SecurityTokenInclusionMode.cs
- Geometry3D.cs
- ADConnectionHelper.cs
- DatagridviewDisplayedBandsData.cs
- HwndHostAutomationPeer.cs
- TitleStyle.cs
- AdornerLayer.cs
- RoleService.cs
- SiteOfOriginPart.cs
- Resources.Designer.cs
- SimpleWorkerRequest.cs
- TypeConstant.cs
- SmiXetterAccessMap.cs
- SafeRightsManagementHandle.cs
- URLIdentityPermission.cs
- ClientConfigurationSystem.cs
- SqlGenerator.cs
- ProxyGenerator.cs
- XmlDigitalSignatureProcessor.cs
- ZipIOExtraFieldZip64Element.cs
- ComplexTypeEmitter.cs
- MethodResolver.cs
- ApplicationCommands.cs
- WebProxyScriptElement.cs
- ContextStack.cs
- DataGridCaption.cs
- MessageSecurityProtocol.cs
- Vector3DAnimationUsingKeyFrames.cs
- Tokenizer.cs
- ipaddressinformationcollection.cs
- LicenseContext.cs
- TableRow.cs
- HtmlTableCell.cs
- WizardStepBase.cs
- ProfilePropertyNameValidator.cs
- PropertyPushdownHelper.cs
- isolationinterop.cs
- BasicBrowserDialog.designer.cs