TypeConverter.ConvertFromString Method (String)

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Converts the specified text to an object.

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

public object ConvertFromString(
	string text
)

Parameters

text
Type: System.String

The text representation of the object to convert.

Return Value

Type: System.Object

An Object that represents the converted text.

Exception Condition
NotSupportedException

The string cannot be converted into the appropriate object.

The default implementation always returns null.

For an example of this function, see the TypeConverter class.

.NET Framework
Available since 1.1
Silverlight
Available since 2.0
Windows Phone Silverlight
Available since 7.0
Return to top
Show: