ThicknessConverter.ConvertFrom Method

Definition

Attempts to create an instance of Thickness from a specified object.

C#
public override object ConvertFrom(System.ComponentModel.ITypeDescriptorContext typeDescriptorContext, System.Globalization.CultureInfo cultureInfo, object source);

Parameters

typeDescriptorContext
ITypeDescriptorContext

The context information for a type.

cultureInfo
CultureInfo

The CultureInfo of the type being converted.

source
Object

The sourceObject being converted.

Returns

An instance of Thickness created from the converted source.

Exceptions

The source object is a null reference (Nothing in Visual Basic).

The example object is not a null reference and is not a valid type that can be converted to a Thickness.

Applies to

Producto Versiones
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
Windows Desktop 3.0, 3.1, 5, 6, 7, 8, 9, 10

See also