ÔÚAJAXÖдÓGridView±íÖÐÎÞ·¨µ¼³öExcel±í¸ñµÄÎÊÌâ
Õ⼸Ì칤×÷£¬ÓõÄÊÇAJAX¿ò¼Ü£¬½á¹ûµ¼³öExcel±í¸ñµÄʱºòÎÞ·¨µ¼³ö¡£
½â¾ö°ì·¨£º1¡¢ÔÚ.aspxÒ³ÃæÊ×ÐÐÖÐ<%@ Page Language="C#" AutoEventWireup="true" CodeFile="JinHuoDan.aspx.cs" Inherits="out_store_JinHuoDan" %> Ìí¼ÓEnableEventValidation="false" £»
2¡¢ÔÚUPdatePanelÖÐÌí¼Ó</ContentTemplate>
<Triggers>
<asp:PostBackTrigger ControlID="Out_excel" />//ÕâÀïµÄIDÖ¸µÄÊÇÄãµ¥»÷µ¼³öExecelµÄ¿Ø¼þ£¬Ê¹Õâ¸ö¿Ø¼þ»Ø·¢¡£
</Triggers>
</asp:UpdatePanel> £»
3¡¢µ¼³öEXCELµÄ´úÂ룺 Response.Clear();
Response.Charset = "GB2312";
Response.AppendHeader("Content-Disposition", "attachment;filename=" + DateTime.Now.ToString("yyyyMMddHHmmss") + ".xls");
Response.ContentEncoding = System.Text.Encoding.UTF7;
Response.ContentType = "application/ms-excel";
System.IO.StringWriter ostrwriter = new System.IO.StringWriter();
HtmlTextWriter ohtwriter = new HtmlTextWriter(ostrwriter);
this.GridView1.RenderControl(ohtwriter);
Response.Output.Write(ostrwriter.ToString());
Response.Flush();
Response.End();
²¢ÇÒÌí¼Ó´úÂëÐУº public override void VerifyRenderingInServerForm(Control control)
{
}
//ÕâÐдúÂëÊÇҪȷÈÏÔËÐÐʱָ¶¨µÄ·þÎñÆ÷¿Ø¼þ³ÊÏÖ£¬Ò»¶¨ÒªÌí¼Ó
ÔËÐнâ¾öÎÊÌâ
Ïà¹ØÎĵµ£º
1.Ajax Rain
¡¡¡¡AjaxRainÓкܶàÍêÃÀÕûºÏAJAX, CSS, DHTML »ò JavascriptµÄʵÀý£¬ÓÐһЩDemoµÄÈ·ÖµµÃÄãÈ¥¿´Ò»¿´£¬¼´Ê¹Äã²»ÊÇÍøÒ³Éè¼Æ(¿ª·¢)ʦ¡£
Ajax/JavascriptʵÀý:
EXT JS Date Picker
jQuery Feed Menu
jGrowl
FastFind Menu – Jquery
Spiffy Accordion
2.Ajax Daddy ......
ÈçºÎ¿ª·¢°²È«µÄAJAXÓ¦ÓÃ
AJAX¼¼ÊõÒѾÊÇÏÖÔÚ×îÁ÷ÐеÄWebÓ¦Óÿª·¢¼¼ÊõÁË£¬µ«ÊÇÓë´Ëͬʱ£¬WebÓ¦ÓÃÒ²³ÉÁËÕâ¸öIT¼Ü¹¹Öа²È«×Èõ£¬×îÈÝÒ×Êܵ½¹¥»÷µÄ²¿·Ö£¬AJAXÓ¦ÓÃÏà±È½ÏÓ봫ͳµÄWebÓ¦Ó㬴ó´óÔö¼ÓÁË¿Í»§¶ËÓë·þÎñÆ÷Ö®¼äµÄ½»»¥£¬Í¬Ê±Ò²Ê¹µÃһЩºǫ́µÄÒµÎñÂß¼½Ó¿Ú±©Â¶¸øÁË¿Í»§¶Ë£¬Èç¹û·þÎñÆ÷¶ËûÓÐ×ã¹»µÄ±£»¤»òÕßûÓжԿͻ§¶ËÇ ......
[Òë]µÚÒ»Õ ½éÉÜ Web ÃÅ»§ÒÔ¼° Dropthings.com
ÔÚÕâ±¾ÊéÖУ¬ÎÒ½«»á¸øÄúչʾÔõÑù½éÉÜÒ»¸ö Ajax£¬Web 2.0 ʽµÄÃÅ»§¡£Õâ¸öÃÅ»§Ê¹Óà ASP.NET 3.5 , ASP.NET AJAX ºÍ .NET 3.5 , ҲʹÓÃÁË LINQ ºÍ SQL Server 2005.ÔÚ´´½¨Ó¦ÓóÌÐòÖУ¬Äã¿ÉÒÔÁ˽⵽£º
±ØÐëÒª×öµÄÉè¼Æ¾ö¶¨ºÍ Web 2.0 Óû§½çÃæÖпÉÓÃÐÔµÄÎÊÌâ
¼Ü¹¹µÄ¸´ÔÓÐԺͷ ......
===============ÏÂÆAjax
================
ʮһ¡¢µÚʮһ¿Î ===¡· ʹÓÃXHR¶ÔÏó·¢ËͺͽÓÊÜÊý¾Ý
a.¼ÌÐøÉÏÃæ²½Öè
2)×¢²á»Øµ÷º¯Êý,ֻдº¯ÊýÃû³Æ(Èç¹û¼ÓÁËÀ¨ºÅ£¬ÄÇô¾Í°Ñº¯Êý·µ»ØÖµ×¢²á¸ø»Øµ÷º¯Êý)
xmlHttp.onreadystatechange = callback;
3)ÉèÖÃÁ¬½ÓÐÅÏ¢
//µÚÒ»²ÎÊýÊÇHttpÇëÇó·½Ê½£¬Ò»°ãÑ¡Ôñget¡¢pos ......
±¾ÊµÀýÖ»ÀûÓõ½JQueryÀà¿â±¾ÉíµÄº¯ÊýºÍ¹¦ÄÜ£¬²»ÐèÒªµÚÈý·½²å¼þµÄÖ§³Ö¡£ÁíÍ⣬ËùÓÐ±íµ¥ÐÅÏ¢¶¼ÊÇÀûÓÃPHPMailerÀà¿âÓʼþµÄÐÎʽ·¢Ë͸ø¹ÜÀíÔ±¡£Èç¹ûÄã¶ÔJQueryµÄ»ù±¾Óï·¨»¹²»ÊǺÜÊìϤ£¬ÇëËÑË÷±¾Õ¾µÄ½Ì³Ì×ÊÔ´¡£Èç¹ûÄã¶ÔPHPMailerÓ÷¨²»ÊìϤ£¬Çë²é¿´±¾Õ¾µÄÁíһƪÎÄÕ¡¶Ê¹ÓÃPHPMailerÀà¿â·¢Ë͵ç×ÓÓʼþ¡·¡£
µÚÒ»²½£¬´´½¨Ò»¸ö±íµ¥HTM ......