Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ASP.NETÖÐΪGridViewÌí¼Óɾ³ýÌáʾ¿ò

ÔÚGridViewÖÐÎÒÃÇ¿ÉÒÔÖ±½ÓÌí¼ÓÒ»¸öCommandFieldɾ³ýÁÐÀ´É¾³ýijÐÐÐÅÏ¢¡£µ«ÎªÁ˱ÜÃâÎó²Ù×÷ÒýÆðµÄÎóɾ³ý£¬ÔÚɾ³ý²Ù×÷ÕßÈòÙ×÷ÕßÔÙÈ·ÈÏÏ£¬ÍêºóÔÙ½øÐÐɾ³ý¡£
¡¡¡¡Ê×ÏÈÎÒÃǸøÎÒÃǵÄGridView Ìí¼ÓÒ»¸öÄ£°åÁУ¬ÈçÏ£º
ÒÔÏÂÊÇÒýÓÃƬ¶Î£º
£¼ASP:TemplateField HeaderText="Delete" ShowHeader="False"£¾
£¼ItemStyle ForeColor="Red" /£¾
£¼ItemTemplate£¾
¡¡£¼asp:LinkButton ID="BtnDelete" runat="server" CausesValidation="False" CommandName="Delete"
Text="Delete"£¾£¼/asp:LinkButton£¾
£¼/ItemTemplate£¾
£¼/asp:TemplateField£¾
¡¡¡¡Æä´ÎÎÒÃǸøÎÒÃÇËùÌí¼ÓµÄÄ£°åÁÐÌí¼Ó£ºOnClientClick="return confirm('È·ÈÏҪɾ³ý´ËÐÐÐÅÏ¢Âð£¿')" £¬ÈçÏ£º
ÒÔÏÂÊÇÒýÓÃƬ¶Î£º
£¼asp:TemplateField HeaderText="Delete" ShowHeader="False"£¾
£¼ItemStyle ForeColor="Red" /£¾
£¼ItemTemplate£¾
¡¡£¼asp:LinkButton ID="BtnDelete" runat="server" CausesValidation="False" CommandName="Delete"
Text="Delete" OnClientClick="return confirm('È·ÈÏҪɾ³ý´ËÐÐÐÅÏ¢Âð£¿')"£¾£¼/asp:LinkButton£¾
£¼/ItemTemplate£¾
£¼/asp:TemplateField£¾


Ïà¹ØÎĵµ£º

asp.netºǫ́Óëǰ̨µÄ»¥Ïàµ÷ÓÃ

Ò».ºǫ́µ÷ÓÃǰ̨
1.Page.ClientScript.RegisterStartupScript(type,"",script);
Àý:
string script = string.Format("<script>alert('Wrong');</script>");
Page.ClientScript.RegisterStartupScript(GetType(), "Load", script);
2.¶ÔÏó.Attributes.Add("ʼþ","script")
Àý:
e.Row.Attributes.Add("on ......

asp.net С²ËÄñ ±Øѧ

1. ´ò¿ªÐµĴ°¿Ú²¢´«ËͲÎÊý£º
´«ËͲÎÊý£º
response.write("<script>window.open('*.aspx?id="+this.DropDownList1.SelectIndex+"&id1="+...+"')</script>")
½ÓÊÕ²ÎÊý£º
string a  = Request.QueryString("id");
string b  = Request.QueryString("id1");
2.Ϊ°´Å¥Ìí¼Ó¶Ô»°¿ò
Button1.Att ......

ASP.NET AJAX ʵÏֵǽÎÞË¢ÐÂ/¶¯Ì¬Ìí¼Ó·þÎñÆ÷¿Ø¼þ

ÔÚ×î½ü¿ªÊ¼½«AJAX¼¼Êõ¼ÓÈëµ½ÈÕ³£µÄ¿ª·¢¹¤×÷ÖС£ÎÒÔÚ×î½üдÁ˸öAJAXµÄÎÞˢеǽÇÒ¶¯Ì¬Ìí¼Ó·þÎñÆ÷¿Ø¼þµÄ¹¤×÷£¬ÎÒ½«´Ë¹¦ÄܸæËß´ó¼ÒÏ£Íû¶Ô´ó¼ÒµÄ¹¤×÷ÓÐËù°ïÖú¡£Èç¹û´ó¼ÒÓиüºÃµÄ·½·¨ÇÒÔ¸ÒâÔÚ´ËÁôÑÔÈÃÎÒÒ²¿ÉÒÔ·ÖÏíµ½ÄãµÄ³É¹û¡£
Ê×ÏÈÔÚÒ³ÃæÖеÄHTML±ê¼ÇÖмÓÈë¿Ø¼þUpdatePanelºÍÁ½¸öTextboxÒ»¸öButton£º
<asp:UpdatePanel ID ......

ÎåÖÖ³£¼ûµÄASP.NET°²È«È±ÏÝ

ÎåÖÖ³£¼ûµÄASP.NET°²È«È±ÏÝ
2004-10-18 19:30×÷Õߣºmenhal ³ö´¦£º¶¯Ì¬ÍøÖÆ×÷Ö¸ÄÏÔðÈα༭£º·½ÖÛ
¡¡¡¡±£Ö¤Ó¦ÓóÌÐòµÄ°²È«Ó¦µ±´Ó±àдµÚÒ»ÐдúÂëµÄʱºò¿ªÊ¼×öÆð£¬Ô­ÒòºÜ¼òµ¥£¬Ëæ×ÅÓ¦ÓùæÄ£µÄ·¢Õ¹£¬ÐÞ²¹°²È«Â©¶´ËùÐèµÄ´ú¼ÛÒ²ËæÖ®¿ìËÙÔö³¤¡£¸ù¾ÝIBMµÄϵͳ¿ÆѧЭ»á£¨Systems Sciences Institute£©µÄÑо¿£¬Èç¹ûµÈµ½Èí¼þ²¿ÊðÖ®ºóÔ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ