MobileTypeNameConverter.ConvertFrom Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Converts the given object to the type of this converter, using the specified context and culture information. This API is obsolete. For information about how to develop ASP.NET mobile applications, see Mobile Apps & Sites with ASP.NET.
public:
override System::Object ^ ConvertFrom(System::ComponentModel::ITypeDescriptorContext ^ ctx, System::Globalization::CultureInfo ^ ci, System::Object ^ data);
public override object ConvertFrom (System.ComponentModel.ITypeDescriptorContext ctx, System.Globalization.CultureInfo ci, object data);
override this.ConvertFrom : System.ComponentModel.ITypeDescriptorContext * System.Globalization.CultureInfo * obj -> obj
Public Overrides Function ConvertFrom (ctx As ITypeDescriptorContext, ci As CultureInfo, data As Object) As Object
Parameters
An ITypeDescriptorContext that provides a format context.
- ci
- CultureInfo
The CultureInfo to use as the current culture.
Returns
An Object that represents the converted value.
Exceptions
Calling GetType() on data
returns null
.
Remarks
This implementation of ConvertFrom casts data
as a string and then calls the GetType method on it. The result, a new Type, is then returned. However, if the result is null
, an exception will be thrown.