I have a control array of buttons on form1 which i have created in a separate class. I have a common event handler for all the buttons that opens up form2, but with a different Tag value, depending on which button was pressed ie button 4 pressed, form2 opens up with text as 4 and tag value of 4.
So, when i create an instance of form2 in form1, does that mean that i am using another instance and not the instance of the form opened by the button? If this is the case, how do i access the form opened in the other class (ButtonArray). Whenever i create an instance of ButtonArray, i get an error message saying that it takes no overloaded arguments, even though i do not pass any parameters.
Also, what i have is that you can open multiple instances of form2, via the click event in the ButtonArray class. The reason for this is that i need to build different strings depending on the number of the screen and then pass this string value to form1 to be used as the last element of an array.
I'm sorry if this is all a bit confusing, but i am new to C# programming.
Thank you!