Author: basquepower | Posted on: 6/18/2008 7:44:59 AM | Views : 306

Hello,
 I am exporting datas from the program to excel page but it doesnÃ?´t do it completely well. It shows all datas well but the only mistake is that all the cells of a page donÃ?´t have borders. The background is completely white.
I�´m using this method to export information:
HtmlTable table;
HtmlTableRow row;
HtmlTableCell cell;
table=new HtmlTable(); 
Response.AddHeader("content-disposition", "attachment;filename=" + archivoNombre);
Response.ContentType = "application/vnd.ms-excel";//"text/xls","vnd.ms-excel";
Response.Clear();
Response.Buffer = true;
Response.Charset = "";
Response.ContentEncoding = System.Text.Encoding.Default;
    
System.IO.StringWriter tw = new System.IO.StringWriter();
System.Web.UI.HtmlTextWriter hw = new HtmlTextWriter(tw);

row = new HtmlTableRow();
row.Align = "cen ...

Go to the complete details ...