P
pat.saunders
Hi,
I am using Visual Studio 2005 and am using Visual C#. I notice
that the program.cs creates an instance of a form and runs it. I have
a PictureBox in the form and a Class File x.cs and in the Class file
x.cs want to access some of the picturebox parameters e.g size but I
do not have access to these parameters. I could write a function in
form.cs to return these parameters but as I don't have access to an
instance of form I cannot call the function . How do I get around this
problem. I know I could pass the PictureBox as a parameter from the
form to the Class but I would like to know how classes interact with
the Form ??
I am using Visual Studio 2005 and am using Visual C#. I notice
that the program.cs creates an instance of a form and runs it. I have
a PictureBox in the form and a Class File x.cs and in the Class file
x.cs want to access some of the picturebox parameters e.g size but I
do not have access to these parameters. I could write a function in
form.cs to return these parameters but as I don't have access to an
instance of form I cannot call the function . How do I get around this
problem. I know I could pass the PictureBox as a parameter from the
form to the Class but I would like to know how classes interact with
the Form ??