471,356 Members | 1,511 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,356 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
Return m_blnReadOnly
End Get
Set(ByVal Value As Boolean)
m_blnReadOnly = Value

If Value Then
Me.HighlightRow = True
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
Return m_blnHighlightRow
End Get
Set(ByVal Value As Boolean)
m_blnHighlightRow = Value
End Set
End Property


Jul 21 '05 #1
0 1057

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

4 posts views Thread by Steve Amey | last post: by
2 posts views Thread by Dave Rudolf | last post: by
1 post views Thread by Paul Cheetham | last post: by
reply views Thread by Job Lot | last post: by
19 posts views Thread by Jamey Shuemaker | last post: by
3 posts views Thread by Dan Soendergaard | last post: by

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.