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

ASP.NETÒ³Ãæ¼ä´«Öµ·½·¨

Ò»¡¢Ä¿Ç°ÔÚASP.NETÖÐÒ³Ãæ´«Öµ¹²ÓÐÕâô¼¸ÖÖ·½Ê½£º
1¡¢±íµ¥Ìá½»£¬
   <form action= "target.aspx" method = "post" name = "form1">
<input name = "param1" value = "1111"/>
<input name = "param2" value = "2222"/>
   </form>
   ....
   form1.submit();
   ....
   ´ËÖÖ·½ÔÚASP¡£NETÖÐÎÞЧ£¬ÒòΪASP¡£NETµÄ±íµ¥×ÜÊÇÌá½»µ½×ÔÉíÒ³Ã棬Èç¹ûÒªÌá½»µ½±ðÒ»Ò³Ã棬ÐèÒªÌØÊâ´¦Àí¡£
2¡¢<A href="target.aspx?param1=1111&param2=2222">Á´½ÓµØÖ·´«ËÍ</A>
½ÓÊÕÒ³Ã棺 string str = Request["param1"]
3¡¢Session¹²Ïí
·¢ËÍÒ³Ã棺Session("param1") = "1111";
°´ÊÕÒ³Ãæ string str = Session("param1").ToString();
4¡¢Application¹²Ïí
·¢ËÍÒ³Ã棺 Application("param1") = "1111";  
°´ÊÕÒ³Ã棺 string str = Application("param1").ToString();
´ËÖÖ·½·¨²»³£Ê¹Óã¬ÒòΪApplicationÔÚÒ»¸öÓ¦ÓóÌÐòÓò·¶Î§¹²Ïí£¬ËùÓÐÓû§¿ÉÒԸı估ÉèÖÃÆäÖµ£¬¹ÊÖ»Ó¦ÓüÆÊýÆ÷µÈÐèҪȫ¾Ö±äÁ¿µÄµØ·½¡£
5¡¢Cookie
6¡¢Response.Redirect()·½Ê½
   Response.Redirect("target.aspx?param1=1111&param2=2222")
   ½ÓÊÕÒ³Ã棺 string str = Request["param1"]
7¡¢Server.Transfer()·½Ê½¡£
   Server.Transfer("target.aspx?param1=1111&param2=2222")
   ½ÓÊÕÒ³Ã棺 string str = Request["param1"]
¶þ¡¢Èç¹ûÔÚÁ½¸öÒ³Ãæ¼äÐèÒª´óÁ¿µÄ²ÎÊýÒª´«´«µÝ£¬ÈçÊý¾Ý²éѯµÈÒ³Ãæʱ£¬ÓÃ1 £­ 6µÄ·½·¨´«Öµ¼°Æä²»±ã£¬¶øµÚ 7 ÖÖ·½·¨È·ÓÐÒ»¶ÀÌصÄÓÅÊÆ£¡µ«Ê¹Óø÷½·¨Ê±ÐèÒªÒ»¶¨µÄÉèÖã¬ÏÖ¼òµ¥½éÉÜһϸ÷½·¨µÄʹÓ÷½Ê½£º
¡¡¡¡ÒÔ²éѯÊý¾ÝÒ³ÃæΪÀý£º
   ÔÚ²éѯҳÃæÖÐÉèÖÃÈçϹ«ÓÐÊôÐÔ(QueryPage.aspx)£º
    public class QueryPage : System.Web.UI.Page
{
protected System.Web.UI.WebControls.TextBox txtStaDate;
protected System.Web.UI.WebControls.TextBox txtEndDate;
   ...
/// <summary>
/// ¿ªÊ¼Ê±¼ä
/// </summary>
public string StaDate
{
get{ return this.txtStaDate.Text;}
set{this.txtStaDate.Text = value;}
}
/// <summary>
/// ½áÊøʱ¼ä
/// </summary>
public string EndDate
{
get{ return thi


Ïà¹ØÎĵµ£º

¹ØÓÚASP.NETÒ³Ãæ´òÓ¡¼¼ÊõµÄ×ܽá

ÍøÂç´òÓ¡¸ÅÊö
¡¡¡¡• B/S½á¹¹µ¼ÖÂÁËWebÓ¦ÓóÌÐòÖдòÓ¡µÄÌØÊâÐÔ¡£
¡¡¡¡• ³ÌÐòÔËÐÐÔÚä¯ÀÀÆ÷ÖУ¬´òÓ¡»úÔÚ±¾µØ£¬¶øÎļþÈ·¿ÉÄÜÔÚ·þÎñÆ÷ÉÏ£¬µ¼ÖÂÁË´òÓ¡¿ØÖƲ»ÊǺÜÁé»î¡£
¡¡¡¡• ¸ñʽÈçºÎ¿ØÖƺͶ¨ÖƵȣ¬ÊÇÎÒÃÇ¿ª·¢ÖпÉÄÜ»áÃæ¶ÔµÄÎÊÌâ¡£
¡¡¡¡´òÓ¡ÎĵµµÄÉú³É
¡¡¡¡• 1¡¢¿Í»§¶Ë½Å±¾·½Ê½
¡¡¡¡Ò»°ãÇé¿öÏ£¬Ö÷ÒªÊ ......

ASP.NET 4µ±ÖÐUrl RoutingµÄÖ§Ô®

ASP.NET 4µÄWeb Formsµ±ÖУ¬×îÁîÈ˼¤É͵ģ¬ÔòĪ¹ýÓÚÊÇURL Routing»úÖƵÄÈ«ÃæÖ§³Ö¡£¹ýÈ¥ÔÚASP.NET 3.5 SP1µ±ÖУ¬Web Forms»ò¶à»òÉپͿªÊ¼Ö§³ÖURL Routing»úÖÆ£¬ËüÈÃÎÒÃÇÔÚÍøÖ·µÄ³ÊÏÖÒÔ¼°Ê¹ÓÃÉϸü¼ÓµÄÓе¯ÐÔ¡£
¹ýÈ¥ÎÒÃÇÔÚASP.NETµ±ÖУ¬Ï°¹ßÓÚµ×ÏÂÕâÑùµÄÍøÖ·³ÊÏÖ·½Ê½£º
http://myWebSite/EditProduct.aspx?Id=1
µ«×î½ü¼¸ÄêR ......

IISÖÐASP.netµ÷ÊÔ³öÏÖ½ø³Ì±»´ò¶ÏµÄµ÷Õû

 
·ÖÀà: ר¼ÒBlog ÍƼöÕߣºadmin| ä¯ÀÀÁ¿£º489 views| 1 ¸öÆÀÂÛ
Èç¹ûÎÒÃÇÓÃIISËÞÖ÷ASP.net£¬µ¥²½µ÷ÊÔʱ£¬»áÓпÉÄÜÏÂÃæµÄÒì³£±¨³öÀ´£º
—————————
Microsoft Visual Studio
—————————
The web serv ......

asp.net±¸·ÝÊý¾Ý¿â


Asp.Net ±¸·ÝºÍ»Ö¸´SQL SERVER Êý¾Ý¿â
   ÎÒÃÇͨ³£±¸·ÝÊý¾Ý¿âʱ£¬ÐèÒªµÇ¼Êý¾Ý¿â·þÎñÆ÷È¥±¸·ÝºÍ»Ö¸´£¬ÕâÑùºÜ²»·½±ã£¬ÆäʵSQL SERVER×Ô´øµÄÃüÁî¿ÉÄÜÈÃÎÒÃǺܼòµ¥µØʵÏÖÔ¶³Ìͨ¹ýAsp.Net±¸·ÝºÍ»Ö¸´Êý¾Ý¿â¡£
BACKUP DATABASE '±»±¸·ÝµÄÊý¾Ý¿âÃû' TO DISK = '±¸·ÝÎļþ·¾¶';
ALTER DATABASE '±»»Ö¸´µÄÊý¾Ý¿âÃû' ......

ASP.NET Öе÷Óô洢¹ý³Ì

ÓÃASP.NETÓëSQL SERVER¿ÉÊÇÔµ·Ý×îºÃÁË£¬ÉÔ´óµÄ³ÌÐòÒ»°ãµÚÒ»ÏÈ¿¼ÂǵÄÊÇSQL SERVER£¬Ö»ÊÇһЩºÜ¿¼ÂǾ­¼ÃµÄ²ÅʹÓÃACCESSµÈÁË¡£ÓÃSQL SERVER£¬ÎªÁËʹÊý¾Ý¿âµÄЧÂʸüºÃ£¬Ò»°ã¶¼»á²ÅÈ¡´æ´¢¹ý³Ì£¬Òò´æ´¢¹ý³ÌÖ´ÐÐËٶȿ죬²¢ÇÒ¿ÉÒÔʵÏÖһЩ¸ß¼¶µÄ²éѯµÈ¹¦ÄÜ¡£±ÈÈç´«ÈëһЩÊý¾Ý²ÎÊý£¬µ«Ö´ÐеÄSQL¹ý³Ì¿ÉÄܲ»Í¬µÈ¡£
¡¡¡¡ÏÂÃæ¾ÍÀ´¸öÀý× ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ