I will give you the advanced technique for doing this using Application Settings:
- On your MainForm, select the first driver instance
- In the Properties Window, scroll to the top and look for (Application Settings)
- Click the + to expand that down
- Click in the Property Binding field, then click the ellipsis button to get a popup window
- The popup window will contain a list of properties, find DisableSubscriptions and click the drop down arrow
- Click the New link at the bottom of the list
- Another window will pop up. In this Window, set the Name to DisablePLC1
- Click OK to the 2 pop up windows to close them both
You will now have created an Application Setting in which its value will control the DisableSubscriptions property of your first driver. You now want to create a Checkbox that controls this Application Setting.
- With your MainForm open in design view, From the Toolbox in the All Windows Forms group, select and add a Checkbox to your form
- In the properties Window, scroll to the top and look for (Application Settings)
- Expand down the Application Settings
- You should now see a property named "Checked" in the Application Setting group
- Select this property and drop down the list to select DisablePLC1
When you run your application, the Checkbox will now control your first PLC driver. You will need to repeat this for each driver. In the example, I said to add the Checkbox to the MainForm, but you are free to add it to any form you choose.