TypeConverter.GetConvertToException(Object, Type) TypeConverter.GetConvertToException(Object, Type) TypeConverter.GetConvertToException(Object, Type) TypeConverter.GetConvertToException(Object, Type) Method

定義

変換を実行できなかった場合にスローされる例外を返します。Returns an exception to throw when a conversion cannot be performed.

protected:
 Exception ^ GetConvertToException(System::Object ^ value, Type ^ destinationType);
protected Exception GetConvertToException (object value, Type destinationType);
member this.GetConvertToException : obj * Type -> Exception
Protected Function GetConvertToException (value As Object, destinationType As Type) As Exception

パラメーター

value
Object Object Object Object

変換対象の Object。オブジェクトを使用できない場合は、nullThe Object to convert, or null if the object is not available.

destinationType
Type Type Type Type

変換しようとした型を表す TypeA Type that represents the type the conversion was trying to convert to.

戻り値

変換を実行できなかった場合にスローされる例外を表す ExceptionAn Exception that represents the exception to throw when a conversion cannot be performed.

例外

このメソッドによって自動的にスローされます。Automatically thrown by this method.

適用対象