T
The Real Andy
OK, please excuse the simple (ambiguous) nature of this question.
I have a winform, set up as a base class. I inherit about 5 instances
from this form, each relating to a db table. Currently I am using some
code in a method that launches the inherited form. In this method I
check if an instance of the form already exists, and give focus if it
does exist. Is there an easier way? I figure if I can some how set up
a static method in the inherited form only, then I can create a
'DoesInstanceExist'method. I could do this, but is possible with an
inherited form, or will I have to override the method in each form?
The second question relates to sqlConnection. How can I make this
accessible in all inherited forms? I guess the more appropriate
question is how do you link dataAdaptors and dataSets in with it. I am
confusing myself now, cause I can half think of a way to do it and am
wondering why I am asking the question!
I have a winform, set up as a base class. I inherit about 5 instances
from this form, each relating to a db table. Currently I am using some
code in a method that launches the inherited form. In this method I
check if an instance of the form already exists, and give focus if it
does exist. Is there an easier way? I figure if I can some how set up
a static method in the inherited form only, then I can create a
'DoesInstanceExist'method. I could do this, but is possible with an
inherited form, or will I have to override the method in each form?
The second question relates to sqlConnection. How can I make this
accessible in all inherited forms? I guess the more appropriate
question is how do you link dataAdaptors and dataSets in with it. I am
confusing myself now, cause I can half think of a way to do it and am
wondering why I am asking the question!