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
- MimePart.cs
- SignedPkcs7.cs
- BufferedReadStream.cs
- __Filters.cs
- InvalidEnumArgumentException.cs
- TransformerTypeCollection.cs
- HttpWriter.cs
- PinnedBufferMemoryStream.cs
- Label.cs
- GlobalItem.cs
- ConfigurationManagerInternal.cs
- TraceLevelStore.cs
- Internal.cs
- Socket.cs
- CaseInsensitiveHashCodeProvider.cs
- OleDbException.cs
- MimeTypeAttribute.cs
- GlobalProxySelection.cs
- DBSqlParserTable.cs
- ScrollProperties.cs
- RTLAwareMessageBox.cs
- MasterPageCodeDomTreeGenerator.cs
- Exceptions.cs
- AmbientEnvironment.cs
- CatalogPartChrome.cs
- TableCell.cs
- RTLAwareMessageBox.cs
- SqlPersonalizationProvider.cs
- LineGeometry.cs
- PrintEvent.cs
- WeakReference.cs
- CallbackValidator.cs
- LayoutUtils.cs
- ProviderCommandInfoUtils.cs
- PersistenceException.cs
- SEHException.cs
- InfoCardRSAPKCS1SignatureDeformatter.cs
- ManagedWndProcTracker.cs
- Rectangle.cs
- CodeStatementCollection.cs
- FtpCachePolicyElement.cs
- CredentialCache.cs
- AxDesigner.cs
- FileEnumerator.cs
- SeekStoryboard.cs
- FieldNameLookup.cs
- CroppedBitmap.cs
- SettingsAttributeDictionary.cs
- ControlType.cs
- PrintController.cs
- FormsAuthentication.cs
- WaitForChangedResult.cs
- _CommandStream.cs
- XamlRtfConverter.cs
- DbRetry.cs
- XPathItem.cs
- OpenTypeLayout.cs
- SelectionChangedEventArgs.cs
- GACMembershipCondition.cs
- Stroke.cs
- GridViewColumnCollectionChangedEventArgs.cs
- FixedSOMFixedBlock.cs
- InternalConfigEventArgs.cs
- CustomAttributeBuilder.cs
- ProviderMetadataCachedInformation.cs
- DrawListViewColumnHeaderEventArgs.cs
- Regex.cs
- ToolStripPanelRenderEventArgs.cs
- Point4DConverter.cs
- EntityCollection.cs
- XamlFilter.cs
- WorkflowServiceBuildProvider.cs
- ResXDataNode.cs
- CopyAction.cs
- TextDecorationLocationValidation.cs
- Int16.cs
- SecurityKeyIdentifierClause.cs
- NamedObject.cs
- DtdParser.cs
- ReaderWriterLock.cs
- EventlogProvider.cs
- OutputBuffer.cs
- ReferenceEqualityComparer.cs
- LinearKeyFrames.cs
- BooleanConverter.cs
- MouseButton.cs
- SqlCacheDependencyDatabase.cs
- MergablePropertyAttribute.cs
- RecordsAffectedEventArgs.cs
- ListParaClient.cs
- VarRemapper.cs
- HashMembershipCondition.cs
- ModuleConfigurationInfo.cs
- WebCategoryAttribute.cs
- StylusPointPropertyUnit.cs
- DataControlImageButton.cs
- MessageBuilder.cs
- ObjectStateEntryDbDataRecord.cs
- XamlGridLengthSerializer.cs
- AsyncCompletedEventArgs.cs