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

asp.netÐÔÄÜÓÅ»¯µÄ¼¸¸ö·½Ãæ

c#£¨»òvb.net£©³ÌÐò¸Ä½ø
1¡¢Ê¹ÓÃÖµÀàÐ͵ÄToString·½·¨
¡¡¡¡ÔÚÁ¬½Ó×Ö·û´®Ê±£¬¾­³£Ê¹ÓÃ"+"ºÅÖ±½Ó½«Êý×ÖÌí¼Óµ½×Ö·û´®ÖС£ÕâÖÖ·½·¨ËäÈ»¼òµ¥£¬Ò²¿ÉÒԵõ½ÕýÈ·½á¹û£¬µ«ÊÇÓÉÓÚÉæ¼°µ½²»Í¬µÄÊý¾ÝÀàÐÍ£¬Êý×ÖÐèҪͨ¹ý×°Ïä²Ù×÷ת»¯ÎªÒýÓÃÀàÐͲſÉÒÔÌí¼Óµ½×Ö·û´®ÖС£µ«ÊÇ×°Ïä²Ù×÷¶ÔÐÔÄÜÓ°Ïì½Ï´ó£¬ÒòΪÔÚ½øÐÐÕâÀà´¦Àíʱ£¬½«ÔÚÍйܶÑÖзÖÅäÒ»¸öеĶÔÏó£¬Ô­ÓеÄÖµ¸´ÖƵ½Ð´´½¨µÄ¶ÔÏóÖС£
¡¡¡¡Ê¹ÓÃÖµÀàÐ͵ÄToString·½·¨¿ÉÒÔ±ÜÃâ×°Ïä²Ù×÷£¬´Ó¶øÌá¸ßÓ¦ÓóÌÐòÐÔÄÜ¡£
int num=1;
string str="go"+num.ToString();
2¡¢ÔËÓÃStringBuilderÀà
¡¡¡¡StringÀà¶ÔÏóÊDz»¿É¸Ä±äµÄ£¬¶ÔÓÚString¶ÔÏóµÄÖØи³ÖµÔÚ±¾ÖÊÉÏÊÇÖØд´½¨ÁËÒ»¸öString¶ÔÏó²¢½«ÐÂÖµ¸³Óè¸Ã¶ÔÏó£¬Æä·½·¨ToString¶ÔÐÔÄܵÄÌá¸ß²¢·ÇºÜÏÔÖø¡£
¡¡¡¡ÔÚ´¦Àí×Ö·û´®Ê±£¬×îºÃʹÓÃStringBuilderÀ࣬Æä.NET ÃüÃû¿Õ¼äÊÇSystem.Text¡£¸ÃÀಢ·Ç´´½¨ÐµĶÔÏ󣬶øÊÇͨ¹ýAppend£¬Remove£¬InsertµÈ·½·¨Ö±½Ó¶Ô×Ö·û´®½øÐвÙ×÷£¬Í¨¹ýToString·½·¨·µ»Ø²Ù×÷½á¹û¡£
¡¡¡¡Æ䶨Òå¼°²Ù×÷Óï¾äÈçÏÂËùʾ£º
int num;
System.Text.StringBuilder str = new System.Text.StringBuilder(); //´´½¨×Ö·û´®
str.Append(num.ToString()); //Ìí¼ÓÊýÖµnum
Response.Write(str.ToString); //ÏÔʾ²Ù×÷½á¹û
3¡¢Ê¹Óà HttpServerUtility.Transfer ·½·¨ÔÚͬһӦÓóÌÐòµÄÒ³Ãæ¼äÖض¨Ïò
¡¡¡¡²ÉÓà Server.Transfer Óï·¨£¬ÔÚÒ³ÃæÖÐʹÓø÷½·¨¿É±ÜÃâ²»±ØÒªµÄ¿Í»§¶ËÖض¨Ïò£¨Response.Redirect£©¡£
4¡¢±ÜÃâʹÓÃArrayList¡£
ÒòΪÈκζÔÏóÌí¼Óµ½ArrayList¶¼Òª·âÏäΪSystem.ObjectÀàÐÍ£¬´ÓArrayListÈ¡³öÊý¾Ýʱ£¬Òª²ðÏä»Øʵ¼ÊµÄÀàÐÍ¡£½¨ÒéʹÓÃ×Ô¶¨ÒåµÄ¼¯ºÏÀàÐÍ´úÌæArrayList¡£asp.net 2.0ÌṩÁËÒ»¸öеÄÀàÐÍ£¬½Ð·ºÐÍ£¬ÕâÊÇÒ»¸öÇ¿ÀàÐÍ£¬Ê¹Ó÷ºÐͼ¯ºÏ¾Í¿ÉÒÔ±ÜÃâÁË·âÏäºÍ²ðÏäµÄ·¢Éú£¬Ìá¸ßÁËÐÔÄÜ¡£
5¡¢Ê¹ÓÃHashTale´úÌæÆäËû×ֵ伯ºÏÀàÐÍ
£¨ÈçStringDictionary,NameValueCollection,HybridCollection£©£¬´æ·ÅÉÙÁ¿Êý¾ÝµÄʱºò¿ÉÒÔʹÓÃHashTable.
6¡¢Îª×Ö·û´®ÈÝÆ÷ÉùÃ÷³£Á¿£¬²»ÒªÖ±½Ó°Ñ×Ö·û·â×°ÔÚË«ÒýºÅ" "ÀïÃæ¡£
//±ÜÃâ
MyObject obj = new MyObject();
obj.Status = "ACTIVE";
//ÍƼö
const string C_STATUS = "ACTIVE";
MyObject obj = new MyObject();
obj.Status = C_STATUS;
7¡¢²»ÒªÓÃToUpper(),ToLower()ת»»×Ö·û´®½øÐбȽϣ¬ÓÃString.Compare´úÌ棬Ëü¿ÉÒÔºöÂÔ´óСд½øÐбȽÏ.
Àý£º
const string C_VALUE = "COMPARE"


Ïà¹ØÎĵµ£º

¿Í¹Û¿´´ýViewState¶ÔAsp.net³ÌÐò×÷ÓúÍÓ°Ïì


Ç°¶Îʱ¼äÓÉÓÚ³ÌÐò³öÏÖÁ˱ȽϴóµÄÐÔÄÜÎÊÌ⣬ÊÓͼ£¨View£©Ö®¼äµÄÌøתËٶȷdz£Âý¡£Í¨¹ýFiddlerµ÷ÊԺͷÖÎö£¬²éÕÒµ½ÊÇÓÉÓÚÔÚÊÓͼ(View)ת»»
£¨PostBack£©¹ý³ÌÖУ¬¿Í»§¶Ë¸ø·þÎñÆ÷¶ËµÄ·¢ËÍ×Ö½ÚÊý·Ç³£´ó£¬Ò»°ãÔÚ30KÒÔÉÏ£¬¾ÍÏ൱ÓÚ¿Í»§¶Ëÿ´Î¶¼Òª¸ø·þÎñÆ÷ÉÏ´«´óÊ®KµÄÊý¾ÝÁ¿£¬ÕâÈç¹ûÊDZȽÏ
ºÃµÄÍøÂç»·¾³ÏÂÍêÈ«ÊÇ¿ÉÒÔºöÂԵģ¬µ«ÊÇÄ ......

CuteEditorÊÇÒ»¿î¹¦Äܷdz£Ç¿´óµÄAsp.net HTML±à¼­Æ÷

CuteEditorÊÇÒ»¿î¹¦Äܷdz£Ç¿´óµÄAsp.net HTML±à¼­Æ÷
 Ò»¡¢CuteEditorµÄÅäÖÃ
      1¡¢½«ÒÔÏÂÎļþ¿¼±´µ½ÄãÕ¾µã¸ùĿ¼ÏµÄbinÄÚ(ÕâЩÔÚCuteEditor6.0/bin϶¼¿ÉÒÔÕÒµ½£©
      CuteEditor.dll£¬
      CuteEditor.ImageEditor.dll£¨6. ......

ASP.NET UpdatePanel ¿Ø¼þ¸ÅÊö


ʹÓà ASP.NET UpdatePanel ¿Ø¼þ¿ÉÉú³É¹¦ÄܷḻµÄ¡¢ÒÔ¿Í»§¶ËΪÖÐÐÄµÄ Web Ó¦ÓóÌÐò¡£Í¨¹ýʹÓà UpdatePanel ¿Ø¼þ£¬¿ÉÒÔË¢ÐÂÒ³µÄÑ¡¶¨²¿·Ö£¬¶ø²»ÊÇʹÓûط¢Ë¢ÐÂÕû¸öÒ³Ãæ¡£Õâ³ÆΪִÐГ²¿·ÖÒ³¸üД¡£°üº¬Ò»¸ö ScriptManager ¿Ø¼þºÍÒ»¸ö»ò¶à¸ö UpdatePanel ¿Ø¼þµÄ ASP.NET ÍøÒ³¿É×Ô¶¯²ÎÓ벿·ÖÒ³¸üУ¬¶ø²»ÐèÒª×Ô¶¨Òå ......

ASP.NETµÄÎå´óÊý¾Ý¿Ø¼þ

ASP.NET Êý¾Ý¿Ø¼þ:GridView,DataList,Repeater ,DetailsView,FormView¡£
ASP.NET Êý¾Ý¿Ø¼þ×ÛÊö£º
1.Ç°3¸öÓÃÓÚ³ÊÏÖ¶àÌõ¼Ç¼,ºóÃæ2¸öÓÃÓÚ³ÊÏÖµ¥ÌõÊý¾ÝÃ÷ϸ,¼´³£ÓõļǼÃ÷ϸ¡£
2.GridViewºÍDetailsView¿Ø¼þµÄ²¼¾Ö¹Ì¶¨,×Ô¶¨ÒåÊý¾ÝÏÔʾµÄ²¼¾Ö¹¦ÄÜÓÐÏÞ,Ò»°ãÊʺϲ¼¾Ö¼òµ¥µÄÊý¾Ý³ÊÏÖ¡£3.DataList,RepeaterºÍFormViewÊý¾Ý¿Ø¼þ ......

ASP.net ÀàºÍÊôÐÔµÄÎÊÌâ

using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using Sy ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ