Natasha Thapa Natasha Thapa - 1 year ago 133
C# Question

MVC LabelFor to replace underscores with CamelCase

my DB model has the column name with "_" in the field name.
is there a way to dislay these values in Camel Case when displaying in the form? like

i am using MVC3 with Razor

@Html.LabelFor(model => model.business_name)

Answer Source

Could you not just use the DisplayAttribute?

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download