hi every body
i have a page that i need to show searched data in it my database is excel suppose i don't know how many columns and rows i need to show all data in a table depend on number of columns if there is one column in excel sheet it drew a table with on columns um if they are column i excel sheet it draw 10 columns in page and so on the header of the table should be the same in excel
how can it be done in asp.net c# ?
use something like that but i need to know how to appened data to html
foreach (DataColumn column in ds.Tables[0].Columns)
{
lblresult.Text = column.ColumnName;
}
to be like that
html.Append("<td>" + ds.Tables[0].Rows[i]["ID"] + "</td>");
this gets me header what about data in rows
foreach (DataRow row in ds.Tables[0].Rows)
{
lblresult.Text = ??? to get values;
}