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

Asp.NetÐÔÄÜÓÅ»¯

(Ò»).Ñ¡Ôñ»á»°×´Ì¬´æ´¢·½Ê½
    ÔÚWebconfigÎļþÅäÖÃ:
    <sessionState mode="???" stateConnectionString="tcpip=127.0.0.1:42424"
         sqlConnectionString="data source=127.0.0.1;Trusted_Connection=yes"
      cookieless="false" timeout="20"/>
     
    Asp.netÓÐÈýÖÖ·½Ê½´æ´¢»á»°×´Ì¬ÐÅÏ¢:
    1. ´æ´¢ÔÚ½ø³ÌÖÐ: ÊôÐÔmode = InProc
       ÌØµã£º  ¾ßÓÐ×î¼ÑµÄÐÔÄÜ£¬ËÙ¶È×î¿ì,µ«²»ÄÜ¿ç¶ą̀·þÎñÆ÷´æ´¢¹²Ïí.
 
    2. ´æ´¢ÔÚ״̬·þÎñÆ÷ÖÐ: ÊôÐÔmode = "StateServer"
       ÌØµã:   µ±ÐèÒª¿ç·þÎñÆ÷ά»¤Óû§»á»°ÐÅϢʱ£¬Ê¹Óô˷½·¨¡£
               µ«ÊÇÐÅÏ¢´æ´¢ÔÚ״̬·þÎñÆ÷ÉÏ£¬Ò»µ©×´Ì¬·þÎñÆ÷³öÏÖ¹ÊÕÏ£¬ÐÅÏ¢½«¶ªÊ§
   
    3. ´æ´¢ÔÚSql ServerÖÐ: ÊôÐÔmode="SqlServer"
       ÌØµã:   ¹¤×÷¸ºÔØ»á±ä´ó£¬µ«ÐÅÏ¢²»»á¶ªÊ§.
   
    ²¹³äÒ»µã£º
       I. ÓÉÓÚÄ³Ð©Ò³Ãæ²»ÐèÒª»á»°×´Ì¬£¬Ôò¿ÉÒÔ½«»á»°×´Ì¬½ûÓÃ:
             ´úÂëÈçÏ£º <%@ Page EnableSessionState="false" %>
       II.Èç¹ûÒ³ÃæÐèÒª·ÃÎʻỰ±äÁ¿µ«²»ÔÊÐíÐÞ¸ÄËüÃÇ£¬¿ÉÒÔÉèÖÃÒ³Ãæ»á»°×´Ì¬ÎªÖ»¶Á:
             ´úÂëÈçÏ£º <%@ Page EnableSessionState="false" %>
   
    ʹÓÃʱ¿ÉÒÔ¸ù¾Ý¾ßÌåÇé¿öÑ¡ÔñijÖÖ·½Ê½
(¶þ).ʹÓÃPage.IsPostBack
    Page.IsPostBack±íʾÊÇ·ñÊÇ´Ó¿Í»§¶Ë·µ»ØµÄ. ³õ´ÎÔËÐÐʱ£¬²»ÊÇ´Ó¿Í»§¶Ë·µ»Ø£¬ËüµÄÖµ
    Ϊfalse,µ±´¥·¢Ò³ÃæÉϵÄʼþ»òË¢ÐÂÒ³ÃæÊ±£¬Page.IsPostBackÓÉÓÚÊǻط¢µÄ£¬Öµ±äΪ


Ïà¹ØÎĵµ£º

ÈÏʶASP.NETÅäÖÃÎļþWeb.config

Ò»¡¢ÈÏʶWeb.configÎļþ
Web.configÎļþÊÇÒ»¸öXMLÎı¾Îļþ£¬ËüÓÃÀ´´¢´æ ASP.NET Web Ó¦ÓóÌÐòµÄÅäÖÃÐÅÏ¢£¨Èç×î³£ÓõÄÉèÖÃASP.NET Web Ó¦ÓóÌÐòµÄÉí·ÝÑéÖ¤·½Ê½£©£¬Ëü¿ÉÒÔ³öÏÖÔÚÓ¦ÓóÌÐòµÄÿһ¸öĿ¼ÖС£µ±Äãͨ¹ýVB.NETн¨Ò»¸öWebÓ¦ÓóÌÐòºó£¬Ä¬ÈÏÇé¿öÏ»áÔÚ¸ùĿ¼×Ô¶¯´´½¨Ò»¸öĬÈϵÄ
Web.configÎļþ£¬°üÀ¨Ä¬ÈϵÄÅäÖÃÉèÖà ......

asp.net ÎÊÌâ,¼±!

±í¼ò½à
"¹«½»Ïß·Êý¾Ý¿â"
ÓõÄsqlÊý¾Ý¿â
admin±í
username
password
admin
admin
busroute ±í
³µ´Î
stop-name-id
Õ¾´Î
Ʊ¼Û
68
4
1
1
34
5
6
1.5
25
6
3
2
Õ¾µã±í
id
stop-name
1
»ð³µÕ¾
³µ´Î±í
id
³µ´Î
1
1
Èç¹ûÒªÓûùÓÚvb.netµÄasp.net±à³Ì
µÇ½µÄʱºò¸ÃÔõô±à³Ì°¡,Êý¾Ý¿âÊÇÓÃsql× ......

ASP.NET ½Å±¾¹ýÂË ·ÀÖ¹¿çÕ¾½Å±¾¹¥»÷

/// <summary>
    /// HTML½âÂë
    /// </summary>
    /// <param name="input"></param>
    /// <returns></returns>
    public string HtmlDecode(string input)
  &nb ......

Asp.NetÇå¿ÕÒ³ÃæËùÓÐtextboxµÄ¼¸ÖÖ·½·¨×ܽá

Asp.NetÇå¿ÕÒ³ÃæËùÓÐtextboxµÄ¼¸ÖÖ·½·¨×ܽá
 ÔÚAsp.NetÖÐÇå¿ÕËùÓÐtextboxÓкü¸ÖÖ·½·¨£¬±¾ÎÄÌṩ¼¸ÖÖ£¬¹©´ó¼Ò²Î¿¼£¡
 
foreach( Control childControl in this.Controls )  
{  
if( childControl is TextBox )  
((TextBox)childControl).Text = "";  
}&n ......

ASP.NET¸÷ÖÖ¿çÒ³Ãæ´«Öµ·½·¨¼¼ÇÉ×ܽá

ASP.NET¸÷ÖÖ¿çÒ³Ãæ´«Öµ·½·¨¼¼ÇÉ×ܽá
 
1.ʹÓÃQueryString±äÁ¿
    QueryStringÊÇÒ»Öַdz£¼òµ¥µÄ´«Öµ·½Ê½£¬Ëû¿ÉÒÔ½«´«Ë͵ÄÖµÏÔʾÔÚä¯ÀÀÆ÷µÄµØÖ·À¸ÖС£Èç¹ûÊÇ´«µÝÒ»¸ö»ò¶à¸ö°²È«ÐÔÒªÇ󲻸߻òÊǽṹ¼òµ¥µÄÊýֵʱ£¬¿ÉÒÔʹÓÃÕâ¸ö·½·¨¡£µ«ÊǶÔÓÚ´«µÝÊý×é»ò¶ÔÏóµÄ»°£¬¾Í²»ÄÜÓÃÕâ¸ö·½·¨ÁË¡£ÏÂÃæÊÇÒ»¸öÀý×Ó£º ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ