¹ØÓÚasp.netµ¼³öExcelʱ¹ØÁªÑ¸À×ÏÂÔØ
ÔÚÀûÓÿªÔ´MyXlsµ¼³öExcelʱ£¬¶ÔÓÚ°²×°×ÅѸÀ׵Ŀͻ§¶Ë£¬µ¼³öʱ»á¹ØÁªÑ¸À×£¬Èç¹ûÓÃѸÀ×ÏÂÔØ£¬ÏÂÔصÄÊÇÕâ¸öÒ³Ãæ¼´aspxÎļþ£¬¶ø·ÇÏëÒªµÄµÄ±¨±í
ΪÁ˽â¾öÕâ¸öÎÊÌâ·Ñ¾¡ÐÄ˼£¬bd£¬Google£¬Ã»ÕÒµ½´ð°¸£¬ºóÀ´×Ô¼º¿´¿´Ô´Â룬ϸϸÑо¿ÁËһϽâ¾öÁË
ѸÀ×ÏÂÔØʱÖض¨Î»ÁË×ÊÔ´£¬ËùÒÔÏÂÔصõ½µÄÊÇÍøÒ³µÄ¡£ÕâÑùÎÒÃÇ¿ÉÒÔÿ´Îµã»÷µ¼³öʱתµ½ÁíÒ»¸öеÄÒ³Ã棬ÔÚÐÂÒ³ÃæµÄpage_loadÖд¦Àí
µ¼³ö£¬µ¼³öʱÓÃѸÀ׾ͻáµÃµ½ÐèÒªµÄ±¨±í¶ø²»ÊÇaspxÎļþ¡£µ«ÊÇ»¹ÓÐÎÊÌ⣬¾ÍÊÇÓÃѸÀ×ÏÂÔصı¨±í¿ÉÄÜ´ò²»¿ª»ò³öÎÊÌ⣬ÕâÑùÓÖ·ÑÁËЩÁ¦Æø£¬ÔÚ
´úÂëÖмÓÈëÁËÁ½ÐдúÂ룬²ÅµÃÒÔ½â¾ö¡£¼´£ºÏÈ°ÑÒªµ¼³öµÄ±¨±íÔÚ·þÎñÆ÷±£´æÒ»·Ý£¬ÔÙsend()
ÏÂÃæÊÇÒ»´úÂëʾÀý£º
private
void ExcelExport(IList< LineLossInfo > lossListExcel)
{
XlsDocument xls = new XlsDocument();
xls.FileName = "LineLossMonthDetail.xls";//Ö¸¶¨ÎļþÃû
Worksheet sheet = xls.Workbook.Worksheets.Add("LineLossMonthDetail");
#region ÉèÖø÷Êý¾ÝÁеĴóС
ColumnInfo colInfo1 = new ColumnInfo(xls, sheet);
colInfo1.ColumnIndexStart = 0;
colInfo1.ColumnIndexEnd = 1;
colInfo1.Width = 15 * 256;
sheet.AddColumnInfo(colInfo1);
ColumnInfo colInfo2 = new ColumnInfo(xls, sheet);
colInfo2.ColumnIndexStart = 2;
colInfo2.ColumnIndexEnd = 2;
colInfo2.Width = 15 * 256;
sheet.AddColumnInfo(colInfo2);
ColumnInfo colInfo3 = new ColumnInfo(xls, sheet);
colInfo3.ColumnIndexStart = 3;
colInfo3.ColumnIndexEnd = 3;
colInfo3.Width = 15 * 256;
sheet.AddColumnInfo(colInfo3);
ColumnInfo colInfo4 = new ColumnInfo(xls, sheet);
colInfo4.ColumnIndexStart = 4;
colInfo4.ColumnIndexEnd = 4;
colInfo4.Width = 15 * 256;
sheet.AddColumnInfo(colInfo4);
ColumnInfo colInfo5 = new ColumnInfo(xls, sheet);
colInfo5.C
Ïà¹ØÎĵµ£º
Îå¡¢ASP.NET Web ·þÎñÆ÷¿Ø¼þºÍä¯ÀÀÆ÷¹¦ÄÜ
²»Í¬µÄä¯ÀÀÆ÷ºÍÏàͬä¯ÀÀÆ÷µÄ²»Í¬°æ±¾Ö§³Ö²»Í¬µÄ¹¦ÄÜ¡£ASP.NET ·þÎñÆ÷¿Ø¼þ»á×Ô¶¯È·¶¨·¢³öÒ³ÃæÇëÇóµÄä¯ÀÀÆ÷£¬²¢Îª¸Ãä¯ÀÀÆ÷³ÊÏÖÊʵ±µÄ±ê¼Ç¡£µ«ÊÇ£¬²¿·Ö¿Ø¼þ¹¦ÄÜÎÞ·¨ÔڽϵͰ汾µÄä¯ÀÀÆ÷ÉϳÊÏÖ£¬Òò´ËÐèÒªÔÚ¾¡¿ÉÄܶàµÄä¯ÀÀÆ÷ÀàÐÍÉϲ鿴ҳµÄÊä³ö£¬ÒÔÈ·±£Ò ......
Áù¡¢ASP.NET Web ·þÎñÆ÷¿Ø¼þÖÐµÄ Tab ¼ü˳Ðò¡¢½¹µãºÍ·ÃÎʼü
ÈôÒªÔöÇ¿ÔÚ ASP.NET ÍøÒ³ÖÐʹÓÿؼþµÄÓû§ÌåÑ飬¿ÉÒÔÖ¸¶¨Óû§Í¨¹ý°´ Tab ¼üÏÔʾ ASP.NET Web ·þÎñÆ÷¿Ø¼þµÄ˳Ðò£¬²¢¿ÉÒÔÖ¸¶¨×î³õ´ò¿ªÒ³Ê±Ò³ÉϵÄÄĸö¿Ø¼þ¾ßÓн¹µã¡£
1¡¢Tab ¼ü˳Ðò
µ±ÔÚä¯ÀÀÆ÷ÖÐÏÔʾҳʱ£¬Óû§¿ÉÒÔʹÓà ......
Æß¡¢ASP.NET Web ·þÎñÆ÷¿Ø¼þºÍ CSS Ñùʽ
Äú¿ÉÒÔͨ¹ýÉèÖø÷ÖÖÍâ¹ÛÊôÐÔ£¨Èç ForeColor¡¢BackColor¡¢Height ºÍ Width£©À´¿ØÖÆ ASP.NET ·þÎñÆ÷¿Ø¼þµÄÍâ¹Û¡£´ËÍ⣬²¿·Ö¿Ø¼þÖ§³Ö¹«¿ª¸½¼ÓÑùʽÏà¹ØÉèÖõÄÑùʽ¶ÔÏó¡£
˵Ã÷£º ASP.NET ÍøÒ³ÔÚÔËÐÐʱ¿ÉÒÔµ±×÷ HTML Ò³¡£ÄúÒò´Ë¿ÉÒÔÊ ......
°Ë¡¢ASP.NET Web ·þÎñÆ÷¿Ø¼þÄ£°å
´ó¶àÊý Web ·þÎñÆ÷¿Ø¼þ¾ßÓÐĬÈϵIJ¼¾ÖºÍÍâ¹Û£¬µ«ÊÇÄú¿ÉÒÔͨ¹ýÉèÖÃÊôÐÔ»òʹÓÃÑùʽÀ´²Ù×ÝËüÃÇ¡£²¿·Ö Web ·þÎñÆ÷¿Ø¼þ»¹ÔÊÐíÄúʹÓÃÄ£°åÀ´×Ô¶¨ÒåÆäÍâ¹Û¡£
Ä£°åÊÇÒ»×é HTML ÔªËغͿؼþ£¬ËüÃǹ¹³É¿Ø¼þÌض¨²¿·ÖµÄ²¼¾Ö¡£ÀýÈ磬ÔÚ DataList Web ·þÎñÆ÷¿Ø¼þÖУ¬Äú¿ÉÒ ......
Ê®¡¢ÒÔ±à³Ì·½Ê½·ÃÎÊ ASP.NET ¿Ø¼þ
1¡¢Web ´°Ìå¿Ø¼þ±êʶ
ASP.NETÍøÒ³ÉϵÄÿһ¸ö¿Ø¼þ¶¼±ØÐëÊÇ¿ÉΨһ±êʶµÄ¡£Í¨³££¬Îª¿Ø¼þµÄ ID ÊôÐÔ·ÖÅäÒ»¸öÖµÀ´Î¨Ò»±êʶ¸Ã¿Ø¼þ¡£¸ÃÖµ½«³ÉΪ¿Ø¼þµÄʵÀýÃû³Æ£¨¼´£¬ÔÚ´úÂëÖÐÒýÓÿؼþËùÒÀ¾ÝµÄÃû³Æ£©¡£ÀýÈ磬Èç¹û½« TextBox ¿Ø¼þµÄ ID ÊôÐÔÉèÖÃΪ Text1£¬Ôò¿ÉÒÔÔ ......