TimeSpanMinutesConverter::ConvertTo Method (ITypeDescriptorContext^, CultureInfo^, Object^, Type^)

 

Converts a TimeSpan to a String.

Namespace:   System.Configuration
Assembly:  System.Configuration (in System.Configuration.dll)

public:
virtual Object^ ConvertTo(
	ITypeDescriptorContext^ ctx,
	CultureInfo^ ci,
	Object^ value,
	Type^ type
) override

Parameters

ctx
Type: System.ComponentModel::ITypeDescriptorContext^

The ITypeDescriptorContext object used for type conversions.

ci
Type: System.Globalization::CultureInfo^

The CultureInfo object used during conversion.

value
Type: System::Object^

The value to convert to.

type
Type: System::Type^

The type to convert to.

Return Value

Type: System::Object^

The String representing the value parameter in minutes.

The system uses the ConvertTo method when writing to a configuration file to convert a TimeSpan to a String.

The following code example shows how to customize the ConvertTo method.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 2.0
Return to top
Show: