Thanks for the quick replies all.
I've inherited a system which consists of a data layer base class.
Classes derive from this and pass the connection info to the base
constructor as such:
base(conn object, string table)
child(conn object) : base (object, table)
The problem is that I need to inherit from Child class, but I need a
way of passing my derived classes table string to the base class, else
it will be looking at the child classes table in the DB, rather than my
new classes.
Is there any way I can do this? I've thought about making that class
an interface, but i'm not sure what I have to do will work like that.
For example:
base(conn object, string table)
child(conn object) : base (object, table)
myclass(conn object)
myclass needs to be inherited from, but on occasion, myclass will also
have to be instantiated. The system I have been given shows DB tables
as represented by classes.
Each class at some point needs to be instantiated so it can be used to
interface with certain tables in the DB.
Anyone know how I can go about doing this? If it's not clear what I
mean, I can post some code examples.
Thanks
.