Share via


Helper.Validate(String, String) Method

Definition

Indicates whether a value can be converted to the specified primitive data type.

public:
 static bool Validate(System::String ^ datatype, System::String ^ valueToValidate);
public static bool Validate (string datatype, string valueToValidate);
static member Validate : string * string -> bool
Public Shared Function Validate (datatype As String, valueToValidate As String) As Boolean

Parameters

datatype
String

The Primitive datatype

valueToValidate
String

The value to validate.

Returns

true if the value can be converted to the primitive data type; otherwise, false.

Applies to