|
-
September 13th, 2006, 02:46 PM
#1
Sharing Class Instances between Forms
Hi,
I need some help! 
If I have my main form, and I declare an instance of a class (SerialPort in my case) in the main form, how can I pass this class instance to a sub form?
In my example, I create a serial port object in my main form, then when the user clicks the settings button, I want them to see a new 'COM Settings' form where they can change the values of the object I created in the main form?
I've tried overloading the constructor and passing it that way with nothing but compiler errors, and I'm not convinced that's the right way to do it.
Thanks!
Regards,
Big Winston
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|