Mimicking C# DataGrid formatting in HTML or XML
-
Experts, I wish to display a C# DataGrid exactly as it appears on a C# Form after saving the DataSet to a file. The format (xml or html) does not matter (I'm assuming these are my only choices). The best I can do so far is: 1. call the DataSet.WriteXMLSchema method to create an xsl file 2. call the DataSet.WriteXML method to create my XML file 3. Create an XslTransform object 4. Load the xsl file via XslTransform.Load 5. Transform my ZML file to HTML via the XslTransform.Transform(source, destination) method However, the HTML file does not contain any of the table formatting (since the generated xsl file doesnt contain table formatting). I realize I can create the XSL file by hand, but I was hoping there was a way to do it automatically such that table formatting is included. Any suggestions, either in creating an XML file with formatting or transforming a standard xml file to html such that formatting is preserved? Thanks in advance.