-
Merging Forms
Hi
I want to create an aplication, that uses plugins.
These plugins should show the controls of their own forms "into" my form (not as an mdi form, more like that white bars in office xp. I use a right-doced container control for that).
The plugins mustn't modify menus or my main-form, they only show their controls and modify a picturebox.
Can anyone help me???
-
Your going to have to write a custom plug in system for you application. How ever you do it, you are going to have to document FULLY how to do it, otherwise, know one will write any plug-ins for it.
Here is how I would start it out:
When your app loads, it reads a file of the installed plug ins for your app. It adds menu items for those plug ins so the user can load them. When the user loads the plug in, your app will create the plug in object, and a panel object(or whatever holding area you would like), and pass a reference of the picturebox that it can modify. The plug in will be responsible for creating the UI, and responding to those events.
That is a pretty quick run down of how I would try it. I have never done this before, but it sounds very interesting.
-
OK...
but thats ab bit "uneasy" for me, because only I want to write those plugins, to switch simply between some algortihms.
someone has told me, that I could use usercontrols for the plugins, that are displayed in that area, which is reservated for the plugins.
in vb6 a usercontrol could change the picturebox with "parent.xx"
the only problem in this way is, that I have to load/unload/reload the controls (=plugins) in the runtime, and I don't know, which controls are registered in my plugin list...