How should I generate HTML to represent class and its properties?

Posted by Mike on Stack Overflow See other posts from Stack Overflow or by Mike
Published on 2011-03-02T18:47:27Z Indexed on 2011/03/02 23:24 UTC
Read the original article Hit count: 190

Filed under:
|

Currently I have a class that represents a document. This document needs to be displayed as HTML. I would like to have a method to call such as GetHTML() that would then call GetHTML() on any properties/sections of the document that needed to be rendered. I was initially thinking about using linq and XElement but am wondering if that may cause issues with certain tags in HTML. Would I better off using an HtmlTextWriter? I am open to any suggestions or best practives for this situation. Thanks!

© Stack Overflow or respective owner

Related posts about c#

Related posts about ASP.NET