Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / CompMod / System / ComponentModel / MultilineStringConverter.cs / 1 / MultilineStringConverter.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.ComponentModel { using System.ComponentModel; using System.ComponentModel.Design; using System.Diagnostics; using System.Globalization; using System.Security.Permissions; ////// Provides a type converter to convert multiline strings to a simple string. /// [HostProtection(SharedState = true)] [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly")] public class MultilineStringConverter : TypeConverter { ////// Converts the given value object to the specified destination type. /// public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType) { if (destinationType == null) { throw new ArgumentNullException("destinationType"); } if (destinationType == typeof(string)) { if (value is string) { return SR.GetString(SR.MultilineStringConverterText); } } return base.ConvertTo(context, culture, value, destinationType); } ////// Gets a collection of properties for the type of array specified by the value /// parameter using the specified context and attributes. /// public override PropertyDescriptorCollection GetProperties(ITypeDescriptorContext context, object value, Attribute[] attributes) { return null; } ////// Gets a value indicating whether this object supports properties. /// public override bool GetPropertiesSupported(ITypeDescriptorContext context) { return false; } } }
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- WebEncodingValidatorAttribute.cs
- Calendar.cs
- ErrorHandler.cs
- FixedFlowMap.cs
- TaskFileService.cs
- DbException.cs
- SystemColors.cs
- DefaultProxySection.cs
- PropertyManager.cs
- StylusCaptureWithinProperty.cs
- SpellerInterop.cs
- Propagator.JoinPropagator.cs
- ManagementEventWatcher.cs
- XmlSchemaSequence.cs
- CustomAttributeFormatException.cs
- DragDeltaEventArgs.cs
- CacheChildrenQuery.cs
- ListenerAdapterBase.cs
- TypeConverterAttribute.cs
- ZipArchive.cs
- Opcode.cs
- WebPartConnectionsConnectVerb.cs
- GridViewCommandEventArgs.cs
- ValidatingPropertiesEventArgs.cs
- GraphicsPathIterator.cs
- TriggerAction.cs
- InstanceCompleteException.cs
- XmlLoader.cs
- PipelineModuleStepContainer.cs
- DesignDataSource.cs
- State.cs
- RemotingConfiguration.cs
- ColorMatrix.cs
- TypeLibConverter.cs
- uribuilder.cs
- MessageQueueCriteria.cs
- PrintController.cs
- GlyphCache.cs
- DataSourceHelper.cs
- ListBindableAttribute.cs
- XmlSchema.cs
- PreservationFileWriter.cs
- DrawListViewItemEventArgs.cs
- PeerNameResolver.cs
- NavigationCommands.cs
- WindowInteractionStateTracker.cs
- Int32AnimationBase.cs
- ResponseBodyWriter.cs
- OleDbRowUpdatedEvent.cs
- LambdaCompiler.ControlFlow.cs
- OleDbReferenceCollection.cs
- DispatcherSynchronizationContext.cs
- RuntimeCompatibilityAttribute.cs
- RuleInfoComparer.cs
- SafeEventHandle.cs
- GlyphsSerializer.cs
- ResourceAttributes.cs
- FixedDocumentPaginator.cs
- ListViewInsertionMark.cs
- ConfigXmlCDataSection.cs
- XPathScanner.cs
- UniqueIdentifierService.cs
- HostProtectionException.cs
- DocumentPaginator.cs
- CodeDomLocalizationProvider.cs
- PlacementWorkspace.cs
- AttributeUsageAttribute.cs
- WebReferencesBuildProvider.cs
- DataStorage.cs
- ScalarConstant.cs
- XmlDigitalSignatureProcessor.cs
- BitmapEffectGeneralTransform.cs
- BinaryKeyIdentifierClause.cs
- DataGridViewRowStateChangedEventArgs.cs
- PackageDigitalSignature.cs
- mansign.cs
- EventDrivenDesigner.cs
- ByteKeyFrameCollection.cs
- ProcessHostFactoryHelper.cs
- RichTextBox.cs
- NativeActivityTransactionContext.cs
- NameValueConfigurationElement.cs
- XmlCharCheckingReader.cs
- SqlDataSourceConnectionPanel.cs
- CodeSnippetExpression.cs
- XmlSchemaInclude.cs
- WebPartEventArgs.cs
- ReceiveContextCollection.cs
- DES.cs
- GraphicsState.cs
- GlyphRunDrawing.cs
- SoapIncludeAttribute.cs
- FilterEventArgs.cs
- EndpointAddress10.cs
- Connector.xaml.cs
- PlatformNotSupportedException.cs
- DataContext.cs
- QueryPageSettingsEventArgs.cs
- Bind.cs
- UriTemplateTableMatchCandidate.cs