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

ASP.NET

Èý¡¢ÈçºÎ£ºÉèÖà ASP.NET Web ·þÎñÆ÷¿Ø¼þÊôÐÔ
      ÔÚ ASP.NET ÍøÒ³ÖУ¬¸ù¾ÝËùÐèµÄÊôÐÔ (Property) ÉèÖÿؼþÉùÃ÷µÄÊôÐÔ (Attribute)¡£
ÄúËùÉèÖõÄÈ·ÇÐÊôÐÔÈ¡¾öÓڿؼþºÍÊôÐÔ¡£ÓйØÌض¨¿Ø¼þµÄÊôÐÔµÄÐÅÏ¢£¬ÇëÔÚ“°ïÖú”Ë÷ÒýÖÐËÑË÷¸Ã¿Ø¼þÀàµÄÃû³Æ£¨ÀýÈ磬“Button Àà (System.Web.UI.WebControls)”£©¡£
ÏÂÃæµÄʾÀýÑÝʾÈçºÎÉèÖà TextBox ¿Ø¼þµÄ MaxLength ÊôÐÔ£º
      <asp:textbox id="TextBox1" runat=server maxlength=20 />
°²È«ËµÃ÷£º TextBox ½ÓÊÜÓû§ÊäÈ룬Õ⽫ÊÇÒ»¸öDZÔڵݲȫÍþв¡£Ä¬ÈÏÇé¿öÏ£¬ASP.NET ÍøÒ³ÑéÖ¤Óû§ÊäÈëÊÇ·ñ²»°üÀ¨½Å±¾»ò HTML ÔªËØ¡£
      ˵Ã÷£º ÔÚ Web ·þÎñÆ÷¿Ø¼þÖУ¬Î´Ó³Éäµ½¸Ã¿Ø¼þÊôÐÔ (Property) µÄÈκÎÊôÐÔ (Attribute) ÒÔÔ­Ñù´«µÝµ½ä¯ÀÀÆ÷¡£
     
      1¡¢ÈçºÎ£º¸ù¾Ý¼òµ¥Öµ»òö¾ÙÉèÖà Web ·þÎñÆ÷¿Ø¼þµÄÊôÐÔ
      Èç¹û Web ·þÎñÆ÷¿Ø¼þÊôÐÔµÄÊý¾ÝÀàÐÍΪ»ùÔªÀàÐÍ£¬Èç String¡¢Boolean »ò numeric ÀàÐÍ£¬ÄÇôֻÐ轫ÊôÐÔÖµÖ¸¶¨¸øÊôÐÔ¼´¿ÉÉèÖÃÊôÐÔÖµ¡£Í¬Ñù£¬Èç¹ûÊôÐÔÖµÔÚö¾ÙÀàÖж¨Ò壬Äú¿ÉÒÔÖ»½«¸Ãö¾ÙÖ¸¶¨µ½ÊôÐÔ¡£
A¡¢ÉèÖûùÓÚµ¥ÖµµÄÊôÐÔÖµ
½«Öµ×÷ΪÎÄ×Ö»ò±äÁ¿Ö¸¶¨£¬ÈçÏÂÃæµÄʾÀýËùʾ£º
Label1.Text = "Hello";
DataGrid1.PageSize = 5;
      B¡¢ÉèÖûùÓÚö¾ÙµÄÊôÐÔÖµ
ʹÓÃÒ»¸öö¾ÙÖµÖ¸¶¨Öµ¡£ASP.NET ¿ÉÒÔ»ùÓÚÊôÐÔµÄÀàÐͽâÎöö¾Ù¡£ÏÂÃæµÄ´úÂëʾÀý²ûÊÍÈçºÎʹÓÃö¾ÙÉèÖÃÊôÐÔ£º
// Uses TextBoxMode enumeration
TextBox1.TextMode = TextBoxMode.SingleLine;
// Uses ImageAlign enumeration
Image1.ImageAlign = ImageAlign.Middle;
 
      2¡¢ÈçºÎ£ºÉèÖà Web ·þÎñÆ÷¿Ø¼þµÄµ¥Î»ÊôÐÔ
      Web ·þÎñÆ÷¿Ø¼þµÄ¿í¶È¡¢¸ß¶ÈºÍÀàËÆÊôÐÔÊÇÒÔµ¥Î»ÉèÖõġ£µ¥Î»ÊÇÒÔ¶ÔÏó£¨Unit ½á¹¹£©µÄÐÎʽʵÏֵģ¬Ê¹ÓÃÕâЩ¶ÔÏó£¬Äú¿ÉÒÔͨ¹ý¶àÖÖ·½Ê½Ö¸¶¨ÖµºÍ¶ÈÁ¿µ¥Î»¡£
·ÉèÖûùÓÚµ¥Î»µÄÊôÐÔ
½«¶Ô Unit ½á¹¹µÄÒýÓ÷ÖÅ䏸¿Ø¼þ¡£
ÏÂÃæµÄ´úÂëʾÀýÑÝʾÍê³ÉÕâÒ»²Ù×÷µÄ¶àÖÖ;¾¶¡£
// Default is pixels.
TextBox1.Width = new Unit(100);
TextBox1.Width = new Unit(100, UnitType.Pixel);
TextBox1.Width = new Unit("100px");
// Cen


Ïà¹ØÎĵµ£º

ASP.NETÊ®¸öÓÐЧÐÔÄÜÓÅ»¯µÄ·½·¨

1. Êý¾Ý¿â·ÃÎÊÐÔÄÜÓÅ»¯
Êý¾Ý¿âµÄÁ¬½ÓºÍ¹Ø±Õ
·ÃÎÊÊý¾Ý¿â×ÊÔ´ÐèÒª´´½¨Á¬½Ó¡¢´ò¿ªÁ¬½ÓºÍ¹Ø±ÕÁ¬½Ó¼¸¸ö²Ù×÷¡£ÕâЩ¹ý³ÌÐèÒª¶à´ÎÓëÊý¾Ý¿â½»»»ÐÅÏ¢ÒÔͨ¹ýÉí·ÝÑéÖ¤£¬±È½ÏºÄ·Ñ·þÎñÆ÷×ÊÔ´¡£ASP.NETÖÐÌṩÁËÁ¬½Ó³Ø(Connection Pool)¸ÄÉÆ´ò¿ªºÍ¹Ø±ÕÊý¾Ý¿â¶ÔÐÔÄܵÄÓ°Ï졣ϵͳ½«Óû§µÄÊý¾Ý¿âÁ¬½Ó·ÅÔÚÁ¬½Ó³ØÖУ¬ÐèҪʱȡ³ö£¬¹Ø±ÕʱÊÕ»ØÁ¬½ ......

asp.net »ù±¾Óï·¨

  Ò»¡¢Î¯ÍÐ
       £¨1£© ίÍÐʱһÖÖÒýÓ÷½·¨µÄÀàÐÍ£¬Ò»µ©ÎªÎ¯ÍзÖÅäÁË·½·¨£¬Î¯Íн«Óë¸Ã·½·¨¾ßÓÐÍêÈ«ÏàͬµÄÐÐΪ£¬Î¯Íз½·¨µÄ´øÅ¶ÓÿÉÒÔÏñ
   ÆäËû·½·¨Ò»Ñù£¬¾ßÓвÎÊýºÍ·µ»ØÖµ£¬
      È磺   public delegate int PerformCa ......

asp.net Òþ²ØÍ¼Æ¬µÄÕæÊµµØÖ·

 Default.aspx CSÎļþ´úÂë
using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
public partial class _De ......

ASP.NET ¼¼ÇÉÆª

 Asp.NetÖм¸ÖÖÏàËÆµÄ±ê¼Ç·ûºÅ: < %=...%>< %#... %>< % %>< %@ %>½âÊͼ°Ó÷¨
´ð: < %#... %>: ÊÇÔڰ󶨿ؼþDataBind()·½·¨Ö´ÐÐʱ±»Ö´ÐУ¬ÓÃÓÚÊý¾Ý°ó¶¨
Èç: < %# Container.DataItem("tit") %>
< %= %>: ÔÚ³ÌÐòÖ´ÐÐʱ±»µ÷Ó㬿ÉÒÔÏÔʾºǫ́±äÁ¿Öµ
Èç:
*.aspx ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ