Converts the specified property value into an instance of the specified type.
Namespace:
Endeca.DataAssembly: Endeca.Data (in Endeca.Data.dll) Version: 2.1.1.0 (2.1.1.620)
Syntax
C# |
---|
public static Object Parse( string propertyValue, Type targetType ) |
Visual Basic (Declaration) |
---|
Public Shared Function Parse ( _ propertyValue As String, _ targetType As Type _ ) As Object |
Visual C++ |
---|
public: static Object^ Parse( String^ propertyValue, Type^ targetType ) |
Parameters
- propertyValue
- Type: System..::.String
Value to convert.
- targetType
- Type: System..::.Type
Type to which propertyValue should be converted.
Remarks
Exceptions
Exception | Condition |
---|---|
System..::.ArgumentNullException | if targetType is null. |
System..::.ArgumentException | if propertyValue is null or empty. |
System..::.ArgumentOutOfRangeException | if targetType does not represent one of: Int64, Double, String, DateTime, TimeSpan, or Geocode, or a corresponding nullable version. |