J
Jeroen CEuppens
Hi
I want to know which type the object is. So I can cast another object to
that Type, I can't use (Type), because I don't know
which Type it will be. I want to use these code, but it gives me the
following errors:
Additional information: 'TypeConverter' is unable to convert
'typecasttest.LijstNode' to 'typecasttest.GetImageNode'.
LijstNode lijst=new LijstNode();
GetImageNode gi=new GetImageNode(); //public class GetImageNode : LijstNode
Type t;
TypeConverter tc =new TypeConverter();
t=gi.GetType();
tc.ConvertTo(lijst,t);
What did I do wrong?
Greetz
JC
I want to know which type the object is. So I can cast another object to
that Type, I can't use (Type), because I don't know
which Type it will be. I want to use these code, but it gives me the
following errors:
Additional information: 'TypeConverter' is unable to convert
'typecasttest.LijstNode' to 'typecasttest.GetImageNode'.
LijstNode lijst=new LijstNode();
GetImageNode gi=new GetImageNode(); //public class GetImageNode : LijstNode
Type t;
TypeConverter tc =new TypeConverter();
t=gi.GetType();
tc.ConvertTo(lijst,t);
What did I do wrong?
Greetz
JC