Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / xsp / System / Web / Configuration / VersionConverter.cs / 1305376 / VersionConverter.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Configuration { using System; using System.ComponentModel; using System.Configuration; using System.Globalization; internal sealed class VersionConverter : ConfigurationConverterBase { public override object ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, object value) { return new Version((string)value); } public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType) { var version = (Version)value; return version.ToString(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Configuration { using System; using System.ComponentModel; using System.Configuration; using System.Globalization; internal sealed class VersionConverter : ConfigurationConverterBase { public override object ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, object value) { return new Version((string)value); } public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType) { var version = (Version)value; return version.ToString(); } } } // 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
- RegexNode.cs
- ByteKeyFrameCollection.cs
- DataServiceContext.cs
- ServerValidateEventArgs.cs
- EdmRelationshipRoleAttribute.cs
- EntitySqlQueryCacheEntry.cs
- TrustLevelCollection.cs
- FileEnumerator.cs
- ClientFormsIdentity.cs
- CompareInfo.cs
- LingerOption.cs
- StringCollectionMarkupSerializer.cs
- SecurityRuntime.cs
- SettingsProviderCollection.cs
- TrackBar.cs
- ScrollViewerAutomationPeer.cs
- UpdateRecord.cs
- FocusWithinProperty.cs
- OdbcConnectionHandle.cs
- XmlSchemaSimpleType.cs
- DrawingDrawingContext.cs
- SafeNativeMemoryHandle.cs
- DataPagerFieldItem.cs
- DateTimeOffsetStorage.cs
- IsolatedStorage.cs
- UserControl.cs
- LayoutManager.cs
- JulianCalendar.cs
- DataGridViewCellEventArgs.cs
- VisualTreeUtils.cs
- DateTimePicker.cs
- DropTarget.cs
- RegionIterator.cs
- MimeWriter.cs
- SmtpDigestAuthenticationModule.cs
- WebDisplayNameAttribute.cs
- SoapTypeAttribute.cs
- VersionConverter.cs
- IconConverter.cs
- DetailsViewModeEventArgs.cs
- Latin1Encoding.cs
- WebPartEditorCancelVerb.cs
- PathFigureCollectionConverter.cs
- PingReply.cs
- MaskedTextBox.cs
- BrushMappingModeValidation.cs
- PreloadedPackages.cs
- FixedSOMTableCell.cs
- WebPartDescription.cs
- ExpressionNode.cs
- DataControlFieldCell.cs
- WindowsToolbarItemAsMenuItem.cs
- FileRecordSequenceHelper.cs
- ServiceManagerHandle.cs
- GlyphElement.cs
- NativeMethods.cs
- UrlMapping.cs
- CreateUserErrorEventArgs.cs
- CheckBox.cs
- Int32Collection.cs
- RemotingSurrogateSelector.cs
- WindowsListViewGroupHelper.cs
- MessageProtectionOrder.cs
- BinaryObjectWriter.cs
- NegationPusher.cs
- ControlParameter.cs
- MultiView.cs
- login.cs
- NavigateEvent.cs
- StructuralObject.cs
- Nullable.cs
- MultiView.cs
- ErrorView.xaml.cs
- IPEndPoint.cs
- ErrorWebPart.cs
- XmlIterators.cs
- MethodSignatureGenerator.cs
- InternalSendMessage.cs
- ObservableDictionary.cs
- CheckedPointers.cs
- NameValueConfigurationElement.cs
- RectConverter.cs
- SymbolType.cs
- XmlCompatibilityReader.cs
- HttpAsyncResult.cs
- QilTernary.cs
- SafeNativeMethodsOther.cs
- SkipStoryboardToFill.cs
- OdbcFactory.cs
- IdentifierCollection.cs
- FixedSOMGroup.cs
- MessageHeaderDescription.cs
- DataGridItemEventArgs.cs
- WeakEventTable.cs
- FullTrustAssemblyCollection.cs
- DataGridViewMethods.cs
- FacetChecker.cs
- LocalTransaction.cs
- ServiceReflector.cs
- XmlSerializerSection.cs