Microsoft - please ....

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

On controls - please make Enabled Overridable. (If I use shadows it don't
work).

Let it be possible to inherit the System::String class. Don't sealed it.

I think there is to many classes that is sealed, and there is to mutch
property that can't be overrided.

Let the user (the developer) control the appearance of the control in
enabled mode.


Regards

Terje Myklebust
Norway
 
I beleave you refere to Enable mode. I have made my own control because of
enabled problem. But because they are inherit of the base class Controls, I
can not do anything with the Enabled property, so I made one I called
MyEnabled. So I have solve that the problem but it took 3 days with hard
and unnecessary work.

I have a very nice string class made in MS VS C++ 6.0. But I can not use
the .NET string class as a base like i do with CString in MFC.

Please Mirosoft, let us developer be able to inherit all .NET classes!
 
BTW:
1. you could register to the EnabledChanged event, override OnEnableChanged
2. you could use StringBuilder if you want to manipulate its content.

I guess string is sealed because its usesd internally for opration which
would break if string ceased to be constant...
think of all the places where you write if(aString == anOtherString).
although String DON'T overload '==' operator, it's just that string are
unique!
it also work switch(myString)
so forget about it!
 
1. I have try that. (perhaps not exactly the same). In OnEnableChanged I
set Enabled to True and do som extra things so the control function like VB6
Enabled. Becase i allready had set Enabled to True in the event, I was not
able tol get a new event when i i the program set Enabled to True. So it
only work one way, from True to False.

The StringBuilder class looks intresting. I will take a closer look at it,
to see if I can use it as a base class for my own class.

Today I have VB6 and VS 6.0 C++ code. I want to move everything to VB.NET
as soon VB.NET can do operator overload. I hope that will be with VB.NET
2005.
 
think of all the places where you write if(aString == anOtherString).
although String DON'T overload '==' operator

Yes it does.


But you're right that there are good reasons to why String is sealed,
and I wouldn't expect that to change.



Mattias
 
Terje said:
Today I have VB6 and VS 6.0 C++ code. I want to move everything to VB.NET
as soon VB.NET can do operator overload. I hope that will be with VB.NET
2005.
in C# you *can* overload oprators... why can't you in vb.net??? and if
you really can't move to C# - it's not that hard.
 
Back
Top