linking to enumeration members in xml comments

  • Thread starter Thread starter tsahiasher
  • Start date Start date
T

tsahiasher

i often see in MSDN and third party component providers link to enum
members in their docs. but if i try to do something like <see
cref="MyEnum.Member1"/> i always get an error from the compiler, that
the member doesn't exist or something. how can i link to members of an
enumeration, like i link to methods in other classes?
 
i often see in MSDN and third party component providers link to enum
members in their docs. but if i try to do something like <see
cref="MyEnum.Member1"/> i always get an error from the compiler, that
the member doesn't exist or something. how can i link to members of an
enumeration, like i link to methods in other classes?

Hmm... it works for me:

using System;

enum Foo
{
Bar
}

class Test
{
/// <see cref="Foo.Bar" />
static void Main()
{

}
}

Could you post a similar short but complete example which fails?

Jon
 
That should work fine if they are in the same namespace (or at least: it is
working for me in VS2008). Otherwise, just put the fully-qualified name of
the enum:

<see cref="Foo.Bar.MyEnum.Member1"/>

Marc
 
Back
Top