Reputation: 5534
I have this enum:
/// <summary>
/// Accoun types enumeration
/// </summary>
public enum AcoountTypeTransaction
{
[Description("Account type debit")]
Debit = 0,
[Description("Account type Credit")]
Credit = 1
}
I want to show descriptions on my intellisense, this is only a sample, i have many enums that must be explained. There is a way to do this
Upvotes: 17
Views: 6528
Reputation: 7804
Using XML document comments In the same manner as you would for the enumeration declaration itself like this.
/// <summary>
/// Account types enumeration
/// </summary>
public enum AcoountTypeTransaction
{
/// <summary>
/// This is the Debug constant.
/// </summary>
[Description("Account type debit")]
Debit = 0,
/// <summary>
/// This is the Credit constant.
/// </summary>
[Description("Account type Credit")]
Credit = 1
}
Upvotes: 31