Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / xsp / System / Web / UI / WebControls / EmptyStringExpandableObjectConverter.cs / 1305376 / EmptyStringExpandableObjectConverter.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls { using System.ComponentModel; using System.Globalization; using System.Security.Permissions; ////// Converts an object to String.Empty so it looks better in the designer property grid. /// internal sealed class EmptyStringExpandableObjectConverter : ExpandableObjectConverter { ////// Returns String.Empty so the object looks better in the designer property grid. /// public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType) { if (destinationType == typeof(string)) { return String.Empty; } throw GetConvertToException(value, destinationType); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls { using System.ComponentModel; using System.Globalization; using System.Security.Permissions; ////// Converts an object to String.Empty so it looks better in the designer property grid. /// internal sealed class EmptyStringExpandableObjectConverter : ExpandableObjectConverter { ////// Returns String.Empty so the object looks better in the designer property grid. /// public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType) { if (destinationType == typeof(string)) { return String.Empty; } throw GetConvertToException(value, destinationType); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- MenuCommands.cs
- MachineKeyConverter.cs
- SourceCollection.cs
- RijndaelManaged.cs
- CqlIdentifiers.cs
- CompilerGlobalScopeAttribute.cs
- CompoundFileDeflateTransform.cs
- TemplateComponentConnector.cs
- RtType.cs
- SqlLiftWhereClauses.cs
- AttributeCollection.cs
- SizeValueSerializer.cs
- SuppressIldasmAttribute.cs
- TextTreeObjectNode.cs
- TextTreeExtractElementUndoUnit.cs
- DebuggerAttributes.cs
- sqlpipe.cs
- StorageEntityTypeMapping.cs
- HttpWriter.cs
- Int32Collection.cs
- ContextProperty.cs
- EnumBuilder.cs
- MobileSysDescriptionAttribute.cs
- ParseChildrenAsPropertiesAttribute.cs
- PagesSection.cs
- MarkupExtensionReturnTypeAttribute.cs
- HttpCapabilitiesEvaluator.cs
- SchemaSetCompiler.cs
- XamlDesignerSerializationManager.cs
- MultipleCopiesCollection.cs
- ListViewHitTestInfo.cs
- HandleRef.cs
- Rect3D.cs
- CommandBindingCollection.cs
- WebConfigurationManager.cs
- StorageAssociationTypeMapping.cs
- HtmlInputButton.cs
- AutomationPatternInfo.cs
- InternalsVisibleToAttribute.cs
- XmlSchemaSimpleContentExtension.cs
- Serializer.cs
- OrderedDictionaryStateHelper.cs
- _TimerThread.cs
- ZipIOFileItemStream.cs
- Color.cs
- SafeIUnknown.cs
- ParameterReplacerVisitor.cs
- DomainConstraint.cs
- HttpRequest.cs
- RegisteredArrayDeclaration.cs
- WindowsButton.cs
- EventLogPermission.cs
- OdbcDataAdapter.cs
- ResourceDescriptionAttribute.cs
- StringSorter.cs
- SimpleHandlerFactory.cs
- TypeListConverter.cs
- EventLogHandle.cs
- RadioButton.cs
- WebPartDescription.cs
- AsyncOperationManager.cs
- SecurityContextSecurityTokenResolver.cs
- ErrorProvider.cs
- GridViewCancelEditEventArgs.cs
- FloaterBaseParaClient.cs
- XPathNodeInfoAtom.cs
- DragDrop.cs
- AttributeXamlType.cs
- GenericEnumerator.cs
- IIS7UserPrincipal.cs
- Directory.cs
- WorkflowServiceAttributes.cs
- URLMembershipCondition.cs
- XmlSchemaChoice.cs
- BitmapPalettes.cs
- ChannelCredentials.cs
- WebPartAddingEventArgs.cs
- Ipv6Element.cs
- InvalidCastException.cs
- DesignRelationCollection.cs
- ServiceMemoryGates.cs
- PathFigureCollection.cs
- HttpCachePolicyWrapper.cs
- ListCommandEventArgs.cs
- EntityKeyElement.cs
- JpegBitmapEncoder.cs
- Block.cs
- DiagnosticTraceSource.cs
- CorrelationManager.cs
- LoginView.cs
- CustomAttribute.cs
- DeferredTextReference.cs
- ComponentChangedEvent.cs
- ListBoxAutomationPeer.cs
- StreamingContext.cs
- UserControlCodeDomTreeGenerator.cs
- XmlDeclaration.cs
- __TransparentProxy.cs
- SharedStatics.cs
- RecordManager.cs