Private/Public components?
I have a form with various controls and menus on it, that I pass to a DLL (as object) for the DLL to access controls on the form.
The DLL is a common security module that connects to a database and retrieves the name of all the controls that a user can access. Each control on the form that is in the list retreived is then made visible to the user (default property of secured controls is visible=false).
This worked fine until I added a ContextMenuStrip to the form. Context menus are not in the Controls collection of a form?
So to access the ContextMenuStrips on the form I need to access the Components.
I can do this from within the DLL as long as I set the components to public with the form1.designer.vb e.g.
Public
componentsAs System.ComponentModel.IContainerThe problem is that if I then go back and change the design of the form, then the scope of components gets changed back to Private?
Anyone out there know if there is any way of stopping this from being changed?
Or another way of accessing the ContextMenuStrips without using components?

