By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,165 Members | 1,499 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,165 IT Pros & Developers. It's quick & easy.

Disabling a Property of a Control

P: n/a
Hi,

Is there a way to disable a property of a contorl so it shows grayed
inside Properties box.

Say I hava a custom buildt panel that inherits from Panel class and
want to draw my own border. So I need to set Panel's Border property
to none and then disable it so I can draw my own.

Any help will be appreciated.

_dino_
Nov 21 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Just Shadow the base class BorderStyle Property and set its to Browsable
attribute to false.

<Browsable(False)> _
Public Shadows Property BorderStyle() As BorderStyle
Get
Return MyBase.BorderStyle()
End Get
Set(ByVal Value As BorderStyle)
MyBase.BorderStyle = Value
End Set
End Property

"Dino Buljubasic" <di**@noplacelikehome.com> wrote in message
news:7k********************************@4ax.com...
Hi,

Is there a way to disable a property of a contorl so it shows grayed
inside Properties box.

Say I hava a custom buildt panel that inherits from Panel class and
want to draw my own border. So I need to set Panel's Border property
to none and then disable it so I can draw my own.

Any help will be appreciated.

_dino_

Nov 21 '05 #2

P: n/a
Thanks

_dino_
On Wed, 11 May 2005 19:44:49 -0500, "Some Guy" <my*****@there.com>
wrote:
Just Shadow the base class BorderStyle Property and set its to Browsable
attribute to false.

<Browsable(False)> _
Public Shadows Property BorderStyle() As BorderStyle
Get
Return MyBase.BorderStyle()
End Get
Set(ByVal Value As BorderStyle)
MyBase.BorderStyle = Value
End Set
End Property

"Dino Buljubasic" <di**@noplacelikehome.com> wrote in message
news:7k********************************@4ax.com.. .
Hi,

Is there a way to disable a property of a contorl so it shows grayed
inside Properties box.

Say I hava a custom buildt panel that inherits from Panel class and
want to draw my own border. So I need to set Panel's Border property
to none and then disable it so I can draw my own.

Any help will be appreciated.

_dino_


Nov 21 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.