asp.netµÄÔÚÏßÈËÊýͳ¼Æ
Ò»°ãÊÇ·ÅÔÚGlobal.asaxÖУ¬´úÂëÈçÏ£º
<%@ Application Language="C#" %>
<mce:script runat="server"><!--
void Application_Start(object sender, EventArgs e)
{
// ÔÚÓ¦ÓóÌÐòÆô¶¯Ê±ÔËÐеĴúÂë
//Application["online"] = 10;//ÉèÖÃĬÈÏÔÚÏßÈËÊý,ÔÚÐéÄâ¿Õ¼äÉÏ£¬ÕâÀï²»»áÖ´ÐÐ
}
void Application_End(object sender, EventArgs e)
{
// ÔÚÓ¦ÓóÌÐò¹Ø±ÕʱÔËÐеĴúÂë
}
void Application_Error(object sender, EventArgs e)
{
// ÔÚ³öÏÖδ´¦ÀíµÄ´íÎóʱÔËÐеĴúÂë
}
void Session_Start(object sender, EventArgs e)
{
// ÔÚлỰÆô¶¯Ê±ÔËÐеĴúÂë
Application.Lock();
if (Application["online"] == null)//ÔÚÐéÄâ¿Õ¼äÉÏ£¬Application_Start²»»áÖ´ÐÐ
Application["online"] = 10;
int online = (int)Application["online"];
online++;
Application["online"] = online;
Application.UnLock();
}
void Session_End(object sender, EventArgs e)
{
// ÔڻỰ½áÊøʱÔËÐеĴúÂë¡£
// ×¢Òâ: Ö»ÓÐÔÚ Web.config ÎļþÖÐµÄ sessionstate ģʽÉèÖÃΪ
// InProc ʱ£¬²Å»áÒý·¢ Session_End ʼþ¡£Èç¹û»á»°Ä£Ê½ÉèÖÃΪ StateServer
// »ò SQLServer£¬Ôò²»»áÒý·¢¸Ãʼþ¡£
Application.Lock();
int online = (int)Application["online"];
online--;
Application["online"] = online;
Application.UnLock();
}
// --></mce:script>
ǰ̨ÕâÑùµ÷ÓÃ
µ±Ç° <%=Application["online"] %> ÈËÔÚÏß
×¢£º
1¡¢
application.lock
...
application.unlock
Ö®¼äµÄ´úÂëÔÚÒ»¸öʱ¿ÌÖ»Äܹ©Ò»¸ö·ÃÎÊÕßʹÓÃ.
Ò²¾ÍÊÇ˵£¬µ±Ò»¸öÓû§ÔÚÖ´ÐÐÉÏÃæÁ½ÕßÖ®¼äµÄ´úÂëʱ,ÆäËûµÄÓû§ÊDz»¿ÉÒÔ·ÃÎÊÕâ¶Î´úÂëµÄ¡£
2¡¢
Application_StartÖ»ÓÐÔÚÍøÕ¾·¢²¼Ö®ºó£¬µÚÒ»µÇ½µ½¸ÃÍøÕ¾µÄÈË£¬²Å»áÖ´ÐÐËü¡£¶øSession_Start£¬Ôò²»¹ÜÊDz»ÊǵÚÒ»¸öÈ˵ǽµ½¸ÃÍ
Ïà¹ØÎĵµ£º
˵µ½·¢ËÍÓʼþ·¢ËÍ£¬ÏÈÌáÒ»ÏÂSMTP(ºÇºÇ£¬¸ßÊÖ¾ÍÌø¹ýÕâÒ»¶Î°É£¡)¡£ SMTPµÄÈ«³ÆÊÇ“Simple Mail Transfer Protocol”£¬¼´¼òµ¥Óʼþ´«ÊäÐÒé¡£ËüÊÇÒ»×éÓÃÓÚ´ÓÔ´µØÖ·µ½Ä¿µÄµØÖ·´«ÊäÓʼþµÄ¹æ·¶£¬Í¨¹ýËüÀ´¿ØÖÆÓʼþµÄÖÐת·½Ê½¡£SMTP ÐÒéÊôÓÚ TCP/IP ÐÒé´Ø£¬Ëü°ïÖúÿ̨¼ÆËã»úÔÚ·¢ËÍ»òÖÐתÐżþʱÕÒµ½ÏÂÒ»¸öÄ¿µÄµØ¡£SMTP ·þ ......
ÈÕÆÚת»¯Ò»
ΪÁË´ïµ½²»Í¬µÄÏÔʾЧ¹ûÓÐʱ£¬ÎÒÃÇÐèÒª¶Ôʱ¼ä½øÐÐת»¯£¬Ä¬ÈϸñʽΪ£º2007-01-03 14:33:34 £¬Òª×ª»¯ÎªÆäËû¸ñʽ£¬ÒªÓõ½DateTime.ToStringµÄ·½·¨(String, IFormatProvider)£¬ÈçÏÂËùʾ£º
using System;
using System.Globalization;
String format="D";
DateTime date=DataTime,Now;
Response.Write(date.ToS ......
»¶Ó½øÈë.NETÉçÇøÂÛ̳£¬Óë200Íò¼¼ÊõÈËÔ±»¥¶¯½»Á÷ >>½øÈë
ASP.NET Êý¾Ý¿Ø¼þ:GridView,DataList,Repeater ,DetailsView,FormView¡£
ASP.NET Êý¾Ý¿Ø¼þ×ÛÊö£º
1.Ç°3¸öÓÃÓÚ³ÊÏÖ¶àÌõ¼Ç¼,ºóÃæ2¸öÓÃÓÚ³ÊÏÖµ¥ÌõÊý¾ÝÃ÷ϸ,¼´³£ÓõļǼÃ÷ϸ¡£
2.GridViewºÍDetailsView¿Ø¼þµÄ²¼¾Ö¹Ì¶¨,×Ô¶¨ÒåÊý¾ÝÏÔʾµÄ²¼¾Ö¹¦ÄÜÓÐÏÞ,Ò»°ã ......
SQL
set ANSI_NULLS ON
set QUOTED_IDENTIFIER ON
go
--°¢»áéªsosuo8.com¸ù¾ÝÍøÂçÉϵĴúÂë½øÐÐÁËÐ޸ģ¬°æȨ¹éÔ×÷ÕßËùÓÐ2009-4-5
--°¢»áéª×öÁËÒ»´ÎÉý¼¶£¬2009-9-27
--ÐÞ¸ÄÊä³ö×ܼǼÊý
ALTER PROCEDURE [dbo].[pagination]
@tblName nvarchar(1000), -- ±íÃû
......
OAÔ´ÂëΪÎÒ¹¤×÷ÊÒ¾«ÐÄ´òÔì,ÓÃÁËÈýÄêµÄʱ¼ä,²ÅÐÞÕýÍêÉƵĴóÐͰ칫ϵͳ.
Ϊ¶ÀÁ¢¿ª·¢,²»´æÔÚ°æȨ¾À·×,²»»á¸øÄú´øÀ´Âé·³,´úÂëÍêÕû£¬Öø×÷ȨµÇ¼ÇºÅ£º2008SR14608.
OA×îÐÂÉý¼¶£¬¹¤×÷Á÷¸üÇ¿´ó£¬±íµ¥¶¨Òå¸üÎȶ¨
ÇëÈÏ×¼ÁªÏµ·½Ê½£¬½÷·À¼Ùð¡£
Ϊ½ÚÔ¼¿ª·¢³É±¾£¬OAÔ´Âë¿ÉÒÔ·ÖÄ£¿é½øÐÐÌṩ
ÓÀ¾Ãά»¤£¬Óг¥2´Î¿ª·¢
Èí¼þ¹¦ÄÜ·ÖΪרҵ° ......