473,395 Members | 1,996 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,395 software developers and data experts.

Changing Custom Control Property

How can I make a property change value of another property at design time? I
have added HighlightRow property to custom DataGrid control. Now I want to
assign this property similar to DataGrid’s ReadOnly property. For instance,
when in property window ReadOnly property is set to True, the HighlightRow
property should be set to true and vice-versa. I did something like this does
not seems to work

Public Shadows Property [ReadOnly]() As Boolean
Get
Return m_blnReadOnly
End Get
Set(ByVal Value As Boolean)
m_blnReadOnly = Value

If Value Then
Me.HighlightRow = True
Else
Me.HighlightRow = False
End If

End Set
End Property

<Browsable(True), Description("Determines whether to highlight current row
when ReadOnly property is set to True. By default set to False."),
DefaultValue(False)> _
Public Property HighlightRow() As Boolean
Get
Return m_blnHighlightRow
End Get
Set(ByVal Value As Boolean)
m_blnHighlightRow = Value
End Set
End Property

Thanks

Jul 21 '05 #1
0 1132

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Steve Amey | last post by:
Hi all I am creating a basic control to perform some tasks, and I want to declare some events to be raised so they can be handled from the form that the control is on. I can create my own Event...
2
by: Dave Rudolf | last post by:
Hi all, I have a System.Windows.Forms.ListBox object that I am putting objects into. These objects are of custom types that I am defining. The list box displays each object by its class name --...
1
by: Paul Cheetham | last post by:
Hi, I am creating a custom control in c#, derived from System.Drawing.Image In my derived control, I want to make the Public property Image into a Protected property, as I only want to...
7
by: Shimon Sim | last post by:
I have a custom composite control I have following property
0
by: Job Lot | last post by:
How can I make a property change value of another property at design time? I have added HighlightRow property to custom DataGrid control. Now I want to assign this property similar to DataGrid’s...
19
by: Jamey Shuemaker | last post by:
I'm in the process of expanding my knowledge and use of Class Modules. I've perused MSDN and this and other sites, and I'm pretty comfortable with my understanding of Class Modules with the...
15
by: rizwanahmed24 | last post by:
Hello i have made a custom control. i have placed a panel on it. I want this panel to behave just like the normal panel. The problem i was having is that the panel on my custom control doesnt...
3
by: Dan Soendergaard | last post by:
I have this code: for (int i = 0; i < this.Controls.Count; i++) { if (this.Controls is ValidationTextBox) { // Change the property of the control here. } }
2
by: pdickson | last post by:
Hi - I am using custom textboxes and I need to be able to set the Text on txb1 based on the Text of txb2. I have simplied my code to the following: Public Class customtextbox Inherits...
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:
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
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.