A
Alexandre
Hi,
i currently know how to instantiate an object
which has no parameters in the constructor.
but i have objects which do have parameters in the
constructor, how do i go about instantiating it.
can some one please point me in the right direction?
i have looked into the activator, and into the
getconstructors as well as get parameters for methods and so on
but for some odd reason i never am able to instantiate my objects
the reason for my problem is this,
WHAT WORKS :
i am taking an object using reflection i am doing the following :
- insert into a data base
- create table
- create and break constraints
- drop tables
- delete from table
- update redord or records
....
WHAT DOES NOT WORK
i am not able to create my obects from a select...
i do my select have everything in the dataset
i iterate through the dataset yet i am unable
to instantiate my objects
my default constructor for my objects is as folows
constructor(int Id)
constructor(int Id, DateTime CreationTime)
the more im thinking about this problem
the less i see solutions and the more im thinking
of having the "int Id" removed and simply put as
a property like the reste of all the objects information....
if anyone has any ideas about this or leads thoughts solutions anything
please
help me out
Alexandre
i currently know how to instantiate an object
which has no parameters in the constructor.
but i have objects which do have parameters in the
constructor, how do i go about instantiating it.
can some one please point me in the right direction?
i have looked into the activator, and into the
getconstructors as well as get parameters for methods and so on
but for some odd reason i never am able to instantiate my objects
the reason for my problem is this,
WHAT WORKS :
i am taking an object using reflection i am doing the following :
- insert into a data base
- create table
- create and break constraints
- drop tables
- delete from table
- update redord or records
....
WHAT DOES NOT WORK
i am not able to create my obects from a select...
i do my select have everything in the dataset
i iterate through the dataset yet i am unable
to instantiate my objects
my default constructor for my objects is as folows
constructor(int Id)
constructor(int Id, DateTime CreationTime)
the more im thinking about this problem
the less i see solutions and the more im thinking
of having the "int Id" removed and simply put as
a property like the reste of all the objects information....
if anyone has any ideas about this or leads thoughts solutions anything
please
help me out
Alexandre