Is there a way to create this using HtmlTextWriter? I am trying to create a method to create html dynamically server-side
<fieldset class='ui-grid-a' data-theme='c'>
Here is a start on the code I am not sure how to create the "data-theme" attribute because there is no enum offered for that..
// Initialize StringWriter instance.
StringWriter stringWriter = new StringWriter();
// Put HtmlTextWriter in using block because it needs to call Dispose.
using (HtmlTextWriter writer = new HtmlTextWriter(stringWriter))
{
foreach (string employee in myList)
{
writer.RenderBeginTag(HtmlTextWriterTag.Fieldset);
writer.AddAttribute(HtmlTextWriterAttribute.Class, "ui-grid-a");
writer.AddAttribute(HtmlTextWriterAttribute., "ui-grid-a");
}
}