Commenting methods in VB.Net 
Author Message
 Commenting methods in VB.Net

I would like to add comments for each of my methods in a class so that they
show up with the intellisense when using the method.  The default methods
have it (such as GetType).  It looks like C# has something using XML does VB
have something like that?

Gary



Tue, 20 Apr 2004 04:02:24 GMT  
 Commenting methods in VB.Net

Quote:
> I would like to add comments for each of my methods in a class so that
they
> show up with the intellisense when using the method.  The default methods
> have it (such as GetType).  It looks like C# has something using XML does
VB
> have something like that?

Gary, if I understand you correctly, you want the following:

<Description("This is a comment for the following method.")> _
Public Sub MyMethod()
    'Do something here...
End Sub

The "Description" Attribute should do the trick...

Cal



Tue, 20 Apr 2004 04:43:33 GMT  
 Commenting methods in VB.Net
Not yet.

--
Jonathan Allen


Quote:
> I would like to add comments for each of my methods in a class so that
they
> show up with the intellisense when using the method.  The default methods
> have it (such as GetType).  It looks like C# has something using XML does
VB
> have something like that?

> Gary



Tue, 20 Apr 2004 04:48:43 GMT  
 Commenting methods in VB.Net
Cal,
Is there any reference I need to add?  I get an error on <Description

Thanks,

Gary

Quote:
> > I would like to add comments for each of my methods in a class so that
> they
> > show up with the intellisense when using the method.  The default
methods
> > have it (such as GetType).  It looks like C# has something using XML
does
> VB
> > have something like that?

> Gary, if I understand you correctly, you want the following:

> <Description("This is a comment for the following method.")> _
> Public Sub MyMethod()
>     'Do something here...
> End Sub

> The "Description" Attribute should do the trick...

> Cal



Tue, 20 Apr 2004 05:08:05 GMT  
 Commenting methods in VB.Net
Gary,
Description is part of the System.ComponentModel namespace.

Only the Property Browser (when designing forms/controls) honors it. The
Object Browser does not respect it!

Hope this helps
Jay


Quote:
> Cal,
> Is there any reference I need to add?  I get an error on <Description

> Thanks,

> Gary


> > > I would like to add comments for each of my methods in a class so that
> > they
> > > show up with the intellisense when using the method.  The default
> methods
> > > have it (such as GetType).  It looks like C# has something using XML
> does
> > VB
> > > have something like that?

> > Gary, if I understand you correctly, you want the following:

> > <Description("This is a comment for the following method.")> _
> > Public Sub MyMethod()
> >     'Do something here...
> > End Sub

> > The "Description" Attribute should do the trick...

> > Cal



Tue, 20 Apr 2004 08:43:44 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. VB.DOC 0.25 has been released - XML comments for VB.NET

2. VB.DOC 0.21 released: XMK comments for VB.NET

3. VB.NET application and CR.NET - Change grouping method at runtime

4. TAPI and VB.net (All comments welcome)

5. Can VB.NET Build Comment Web Pages

6. Revisited - VB.NET Build Comment Web Pages

7. vb.net comments

8. Documentation Comments for VB.NET

9. Documentary comments in VB.NET ?

10. Build comment Web Pages ... in VB.NET

11. Comment to the VB/NET Help file writers...

12. create a VB.NET Comment Web Page

 

 
Powered by phpBB® Forum Software