How to add description to user management property in vb.net

I created one web user control named "ReadonlyField" with a boolean data type. I can use it on my web pages, and now I wanted to add a description to this property, so I do not need to explain to my team member what kind of intention this is.

I got the following snippet in C #, but did not find the equivalent in vb.net, and also not sure if it will work or not.

[Description("My Description")]
public int MyIntProperty
{
    get {..}
    set {..}
}
+3
source share
2 answers

Literal translation in VB 10

<Description("My Description")> Public Property MyIntProperty As Integer

If this is for other programmers, you can offer Intellisense support through XML comments. This is the standard way to do this in both VB and C #.

B. B.

 ''' <summary>
 ''' Description goes here
 ''' </summary>
 ''' <value></value>
 ''' <returns></returns>
 ''' <remarks></remarks>
 Public Property MyIntProperty As Integer
+2

, , Intellisense...

 ''' <summary>
 ''' Returns "INSTALLATION ACTION INITIATED"
 ''' </summary>
 ''' <value></value>
 ''' <returns></returns>
 ''' <remarks></remarks>
 Public ReadOnly Property IAS
     Get
         Return _dict("IAS")
     End Get
 End Property
0

Source: https://habr.com/ru/post/1753982/


All Articles