473,385 Members | 1,356 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Disabling a Property of a Control

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
2 887
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
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 thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Lyn | last post by:
Hi, I hope someone can help. I have a main form which mostly fills the Access window. In the bottom half of this form I have a tab control to display various types of data related to the main...
0
by: Josef Meile | last post by:
Hi I wanted to programmatically disable events like SelectedIndexChanged without using a boolean flag, which indeed I find a quick and dirty solution. So, I found a piece of code that do this...
0
by: Bob | last post by:
I implemented a ScrollableControl and only want vertical scrolling. Every time I make the form smaller then the control the control has h scroll bars even though I set it to false. I have the...
1
by: Kuups | last post by:
Hi! I have a question is there any way of disabling the Copy, Paste, Delete ? of a Windows Control Tex Box Right Click Property during runtime ? Thanks!
0
by: R. MacDonald | last post by:
Hello, Group, I have an application that contains a large number of controls of a few different types (all custom defined). During certain specific drag-drop operations, I would like to be able...
8
by: ameen.abdullah | last post by:
Hi Guys, I have a checked list box on my form.. the purpose of this checkbox is to indicate that the option is enabled or disabled.. I just want to ask if there is a way to disable these check...
11
by: EagleRed | last post by:
I am writing an ASP.NET 2.0 application that uses master pages. I have some pages that must not be cached on the client. In ASP.NET 1.1 I achieved this using metatags: <meta...
1
by: Garg | last post by:
Hi i want to disable soem months in my calendar control. I dont want to display certain months at all in my calendar. How do i do that? Shivani
5
by: jehugaleahsa | last post by:
Hello: I am sure this question comes up a lot. I need to disable the controls on my Windows forms so that when the BindingSource is empty some the controls bound to it will be disabled. This...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.