I want to expose a globalized help text on to an MVC view.
Currently the code looks like this,
Custom attribute class
class HelpTextAttribute : Attribute
{
public string Text { get; set; }
}
View model property and custom annotation
[HelpText(Text = "This is the help text for member number")]
public string MemberNo { get; set; }
(The literal string must come from a resource class)
The question is how do i write an Html extension that could do the following
@Html.HelpTextFor(m => m.MemberNo)