-
Control Resize Grab bars
Hi,
I am creating a set of controls. Some of which I don't want to allow vertical, or at times horizontal resizing.
So far I have just been catching the resize event in my code and denying verticle or horizontal resizing as appropriate. There must be a better way. If you look at the Text box control when MultiLine is turned off, VB.NET will not allow you to even use the verticle Resize bars. That is what I want my controls to do at design time. Does anyone know how to do that?
I'm quite new to VB.NET though I have done years of VB6 so don't worry about using complex example code.
Any help would be extremely appreciated.
Cheers,
Angelus
-
What if you declare the height property readonly?
/Leyan
-
Yeah, I see what you are getting at, but like the textbox I want to be able to change the control at runtime. For example I have rapped the textbox with another control (a label) and I want the height to be the same as the textbox. I don't want the user to be able to change the height unless the MultiLine property is set to true.
I want to make a control behave like the textbox control does, basically. Other controls I want to be fixed width etc.
Cheers,
Angelus