I'm not very good at VB yet so bear with me. So I have used VB to create a single form application, with a serial port and everything works fine. I want to elaborate on my application by adding more forms.
My first instinct was to add the serial port to each form that it was going to be used on. But this was giving me errors, after some researching I found that "I should be putting all the serial port functionality into a single class and then all the forms can access it there." As posted by jmcilhinney in another topic.
I dont understand completely what that means.
Should i be making a separate class and add the SerialPort1.Open(), and all of my SerialPort1.Write(" ")'s in to one class? And where do i put said class?
If someone could give me an example of the class i'm suppose to make that would be awesome. The classes i have are all the computer generated ones by double clicking on the components of the form design tab.
My first instinct was to add the serial port to each form that it was going to be used on. But this was giving me errors, after some researching I found that "I should be putting all the serial port functionality into a single class and then all the forms can access it there." As posted by jmcilhinney in another topic.
I dont understand completely what that means.
Should i be making a separate class and add the SerialPort1.Open(), and all of my SerialPort1.Write(" ")'s in to one class? And where do i put said class?
If someone could give me an example of the class i'm suppose to make that would be awesome. The classes i have are all the computer generated ones by double clicking on the components of the form design tab.