RibbonControlLengthConverter.ConvertTo 方法 (ITypeDescriptorContext, CultureInfo, Object, Type)

RibbonControlLength 结构的实例转换为指定类型的实例。

命名空间:  Microsoft.Windows.Controls.Ribbon
程序集:  RibbonControlsLibrary(在 RibbonControlsLibrary.dll 中)

语法

声明
Public Overrides Function ConvertTo ( _
    context As ITypeDescriptorContext, _
    culture As CultureInfo, _
    value As Object, _
    destinationType As Type _
) As Object
public override Object ConvertTo(
    ITypeDescriptorContext context,
    CultureInfo culture,
    Object value,
    Type destinationType
)
public:
virtual Object^ ConvertTo(
    ITypeDescriptorContext^ context, 
    CultureInfo^ culture, 
    Object^ value, 
    Type^ destinationType
) override
abstract ConvertTo : 
        context:ITypeDescriptorContext * 
        culture:CultureInfo * 
        value:Object * 
        destinationType:Type -> Object 
override ConvertTo : 
        context:ITypeDescriptorContext * 
        culture:CultureInfo * 
        value:Object * 
        destinationType:Type -> Object 
public override function ConvertTo(
    context : ITypeDescriptorContext, 
    culture : CultureInfo, 
    value : Object, 
    destinationType : Type
) : Object

参数

  • destinationType
    类型:System.Type
    要将值转换到的类型。

返回值

类型:System.Object
转换后的值。

异常

异常 条件
ArgumentNullException

destinationType 为 null。

ArgumentException

value 不是 RibbonControlLength

- 或 -

destinationType 不是有效的转换类型。

.NET Framework 安全性

请参见

参考

RibbonControlLengthConverter 类

ConvertTo 重载

Microsoft.Windows.Controls.Ribbon 命名空间