Olaf, I am new to .NET and not quite follow the way you described
here(using System.Windows.Forms.UserControl). Do you have some examples
or links I can play with it?
I believe that this link will help you a little further:
http://www.akadia.com/services/dotnet_user_controls.html
It is C# but these controls can then be used in managed C++.
You will discover that mixing C#, VB.NET and managed C++ is fun.
Although at this moment, you cannot create one dll (assemblie) with C# and
managed C++ together. You must crate a C# assemblie (dll) and then use it in
the managed C++. But I believe that VS2005 could do just that.
This way you can create custom controls in a modular way.
One example is I have a static text a slider and a spinbutton together in a
usercontrol (looks like a form) then I put the code behind it that
synchronizes the spin button with the slider and the other way around. The
static text is used as description.
Now in a late stage, I create another usercontrol and put these
slider+spinbutton control on that newly created usercontrol. I use this to
move something in a 3D scene , so I have an X, Y and Z slider+spinbutton.
Finally in my result project I use that last created custom control by drag
and drop.
So you can create a custom control using other custom controls using other
custom controls using ....
Coming from a MFC C++ backrgound moving into the .NET way of thinking will
be a steep learning curve, but it is very rewarding and you will notice that
the develop cycle is far much shorter. I prefer C# now since it is a
lightning fast compiler, but other parts of my code is still C++ too.
There is one issue about .NET that you must be aware of, that it has an
increased security so your programs might not run imemdiately on a machine
when you try to access a LAN folder or Internet. The administrator of that
machine should give enough execution rights, but luckily enough if you
create a setup project, no need of advanced user knowledge is needed if you
wish to distribute a program that needs LAN and Internet access. This
configuration could be done automatically.
One thing I wish Microsoft would implement in the next .NET is a user
friendly way of saying that this program does nt have enough rights to
execute on that machine. Right now, you get a scare error that looks like an
access violation dialog box, and it will take the user years of
psychotherapie to recover from that trauma. ;-) One solution might be a
dialog box with a simple explanation that this program might not have enough
rights to run or that the .NET framework is not installed yet, and an
advanced button the gives more details.
Another problem is that installing the .NET framework is aparently a very
scary thing to do, since I have had so many users now that just refuses to
install it. You have no idea what reasoning they had not to install the .NET
framework but all based on superstition. Luckily, it is getting more and
more accepted. I still believe that Microsoft should have promoted the .NET
installation on the Windows updated like they did with SP2.
Have a lot of fun