N
Norbert Pürringer
Hello,
Imagine, that I've got a string variable containing a value of each
possible value type (string, int32, double, ...). Now I want to
convert the string to an object of the right type, where the correct
type is given by a Type variable.
So given is:
string strValue;
Type typeValue;
And I want to call something like
object value = Convert.ToType(strValue, typeValue);
Is there a simple way to do that?
Thank you,
Norbert
Imagine, that I've got a string variable containing a value of each
possible value type (string, int32, double, ...). Now I want to
convert the string to an object of the right type, where the correct
type is given by a Type variable.
So given is:
string strValue;
Type typeValue;
And I want to call something like
object value = Convert.ToType(strValue, typeValue);
Is there a simple way to do that?
Thank you,
Norbert