• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 337
  • Last Modified:

Creating HTML Helpers for Razor

I expect to code 15-20 HTML Helpers which are needed to keep my Razor files simple and to keep the HTML out of the Model.

We will be using XML as the data source and need to add the resulting values into list boxes, drop down losts, labels, etc. on the cshtml files.

Can you explain best practices for this and provide some sample code?

Thanks.
0
newbieweb
Asked:
newbieweb
1 Solution
 
Friman001Commented:
You would want to use a XmlDataSource and just DataBind specific column to the differnt controls.
0
 
newbiewebSr. Software EngineerAuthor Commented:
Thanks.
0

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now