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

asp.net Öиıädatagrid µÄÁпí

private void Page_Load(object sender, System.EventArgs e)
{

DataGrid1.Columns[0].HeaderText = "ÎÄÕ±êÌâ";
DataGrid1.Columns[1].HeaderText = "·¢²¼ÈÕÆÚ";
DataGrid1.Columns[0].HeaderStyle.HorizontalAlign = HorizontalAlign.Center;
DataGrid1.Columns[1].HeaderStyle.HorizontalAlign = HorizontalAlign.Center;
///' ֻΪ Header ÐÐÌí¼Ó¿í¶È
DataGrid1.Columns[0].HeaderStyle.Width = System.Web.UI.WebControls.Unit.Percentage(72);
DataGrid1.Columns[1].HeaderStyle.Width = System.Web.UI.WebControls.Unit.Percentage(28);
DataGrid1.Style.Add("table-layout", "fixed");
}


Ïà¹ØÎĵµ£º

ASP.NET ¹Ø±Õ½ø³Ì

--aspxÎļþ
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="NetWork.aspx.cs" Inherits="NetWork" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<he ......

asp.netÐÔÄÜÓÅ»¯×ܽá

1. C#ÓïÑÔ·½Ãæ
1.1 À¬»ø»ØÊÕ
¡¡À¬»ø»ØÊÕ½â·ÅÁËÊÖ¹¤¹ÜÀí¶ÔÏóµÄ¹¤×÷£¬Ìá¸ßÁ˳ÌÐòµÄ½¡×³ÐÔ£¬µ«¸±×÷ÓþÍÊdzÌÐò´úÂë¿ÉÄܶÔÓÚ¶ÔÏó´´½¨±äµÃËæÒâ¡£
¡¡1.1.1 ±ÜÃâ²»±ØÒªµÄ¶ÔÏó´´½¨
¡¡ÓÉÓÚÀ¬»ø»ØÊյĴú¼Û½Ï¸ß£¬ËùÒÔC#³ÌÐò¿ª·¢Òª×ñÑ­µÄÒ»¸ö»ù±¾Ô­Ôò¾ÍÊDZÜÃâ²»±ØÒªµÄ¶ÔÏó´´½¨¡£ÒÔÏÂÁоÙһЩ³£¼ûµÄÇéÐΡ£
¡¡1.1.1.1 ±ÜÃâÑ­»·´´½¨¶ÔÏ ......

asp.netÒ³Ãæ´íÎó´¦Àí

asp.net´íÎó´¦Àí·½·¨ ´ó²¿·Ö¶¼Óà try catch
ÎÒÃÇÒ²¿ÉÒÔÔÚÒ³Ã涨Òå  protected void Page_Error(object sender, EventArgs e)·½·¨´¦Àí´íÎóÐÅÏ¢
{
 //ÏÈ»ñÈ¡µ±Ç°·¢ÉúÒì³£
  Exception ex = Server.GetLastError().GetBaseException();
        if (ex is ArgumentOu ......

asp.net ·µ»ØÉÏÒ»Ò³µÄʵÏÖ·½·¨

·µ»ØÉÏÒ»Ò³µÄÕâ¸ö¶«¶«ÔÚÎÒÃÇ×öÏîÄ¿µÄʱºòÒ»°ãÊÇÓÃÓÚÌîдÍê±íµ¥ºóÈ·ÈϵÄʱºò£¬ÓжÔÔ­À´ÊäÈëµÄÊý¾Ý½øÐÐÐÞ¸Äʱ
Óõģ¬»òÕßÊÇÒòΪÍøվΪÁË·½±ãä¯ÀÀÕ߶øÓÐÐÄÌí¼ÓµÄÒ»¸ö¶«¶«£¬Ò»°ãÕâÖÖ¹¦ÄܵÄʵÏÖÔÚASP.netÖж¼ÊÇÓÃÒ»¸öbuttonµÄ¿Ø¼þÀ´ÊµÏֵģ¬ÊµÏֵķ½·¨ÓкÜ
¶à£¬½ñÌìÇ¡ºÃÔÚ×öÏîĿʱÅöµ½ÒªÓÃÕâ¸ö¶«¶«£¬ÎҾͰÑÄÜʵÏÖ" · ......

ASP.NET¿Ø¼þ¿ª·¢»ù´¡Ö®ÀàÐÍת»»Æ÷dzÎö

ASP.NET¿Ø¼þ¿ª·¢»ù´¡Ö®ÀàÐÍת»»Æ÷1.ÈÏʶĬÈÏÊôÐÔä¯ÀÀÆ÷Ö§³Ö
ÈÃÎÒÃÇÔÙÈÏʶһÏÂÊôÐÔ,´ó¼ÒÖªµÀÿ¸öÊôÐÔ¶¼ÊÇÓÐÀàÐ͵Ä,×îÊìϤ¾ÍÊÇstring,intÕâЩÀàÐÍÁË,VS2005ÊôÐÔä¯ÀÀÆ÷¶ÔÕâЩÊôÐÔÀàÐͽøÐÐÁËʶ±ð,
ÈçÏÂÀý×Ó
(1)table¿Ø¼þµÄHeightÊôÐÔ,µ±ÄãÉèÖÃÊôÐÔΪ×Ö·û´®Ê±,ÔòÌáʾ´íÎóÐÅÏ¢
 
(2)µ±ÊôÐÔÀàÐÍΪColorÊôÐÔʱ,ÊôÐÔä¯ÀÀÆ÷ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ