Text property hidden at design time in user control

The Claw

New member
Joined
Nov 21, 2005
Messages
2
Programming Experience
10+
I have written a user control with two properties, text and blockcolor (see below for code).
The problem is that the Text property is not visible at design time, whilst the BlockColor property is.
What's wrong?

Property BlockColor() As Color
Get
Return (mBlockColor)
End Get
Set(ByVal Value As Color)
mBlockColor = Value
Block.BackColor = mBlockColor
End Set
End Property

Public Overrides Property Text() As String
Get
Return (TextBox1.Text)
End Get
Set(ByVal Value$)
TextBox1.Text = Value
End Set
End Property
 
Not too sure about this one. The thing is i've never seen a property written like your text one before.

Normally the AS clause in the set block would be the same as the AS clause in the opening property statement. Anyway You could try importing the system.componentmodel NameSpace and using

<Browsable(true)> _

directly above the property statement. Make sure you write it exactly as it is above , including the space.
 
Back
Top