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

C#(ASP.Net)»ñÈ¡µ±Ç°Â·¾¶µÄ·½·¨¼¯ºÏ

//»ñÈ¡µ±Ç°½ø³ÌµÄÍêÕû·¾¶£¬°üº¬ÎļþÃû(½ø³ÌÃû)¡£  
string str = this.GetType().Assembly.Location;  
result: X:\xxx\xxx\xxx.exe (.exeÎļþËùÔÚµÄĿ¼+.exeÎļþÃû)  
//»ñÈ¡Ð嵀 Process ×é¼þ²¢½«ÆäÓ뵱ǰ»î¶¯µÄ½ø³Ì¹ØÁªµÄÖ÷Ä£¿éµÄÍêÕû·¾¶£¬°üº¬ÎļþÃû(½ø³ÌÃû)¡£  
string str = System.Diagnostics.Process.GetCurrentProcess().MainModule.FileName;  
result: X:\xxx\xxx\xxx.exe (.exeÎļþËùÔÚµÄĿ¼+.exeÎļþÃû)  
//»ñÈ¡ºÍÉèÖõ±Ç°Ä¿Â¼£¨¼´¸Ã½ø³Ì´ÓÖÐÆô¶¯µÄĿ¼£©µÄÍêÈ«ÏÞ¶¨Â·¾¶¡£  
string str = System.Environment.CurrentDirectory;  
result: X:\xxx\xxx (.exeÎļþËùÔÚµÄĿ¼)  
//»ñÈ¡µ±Ç° Thread µÄµ±Ç°Ó¦ÓóÌÐòÓòµÄ»ùĿ¼£¬ËüÓɳÌÐò¼¯³åÍ»½â¾ö³ÌÐòÓÃÀ´Ì½²â³ÌÐò¼¯¡£  
string str = System.AppDomain.CurrentDomain.BaseDirectory;  
result: X:\xxx\xxx\ (.exeÎļþËùÔÚµÄĿ¼+"\")  
//»ñÈ¡ºÍÉèÖðüº¬¸ÃÓ¦ÓóÌÐòµÄĿ¼µÄÃû³Æ¡£  
string str = System.AppDomain.CurrentDomain.SetupInformation.ApplicationBase;  
result: X:\xxx\xxx\ (.exeÎļþËùÔÚµÄĿ¼+"\")  
//»ñÈ¡Æô¶¯ÁËÓ¦ÓóÌÐòµÄ¿ÉÖ´ÐÐÎļþµÄ·¾¶£¬²»°üÀ¨¿ÉÖ´ÐÐÎļþµÄÃû³Æ¡£  
string str = System.Windows.Forms.Application.StartupPath;  
result: X:\xxx\xxx (.exeÎļþËùÔÚµÄĿ¼)  
//»ñÈ¡Æô¶¯ÁËÓ¦ÓóÌÐòµÄ¿ÉÖ´ÐÐÎļþµÄ·¾¶£¬°üÀ¨¿ÉÖ´ÐÐÎļþµÄÃû³Æ¡£  
string str = System.Windows.Forms.Application.ExecutablePath;  
result: X:\xxx\xxx\xxx.exe (.exeÎļþËùÔÚµÄĿ¼+.exeÎļþÃû)  
//»ñȡӦÓóÌÐòµÄµ±Ç°¹¤×÷Ŀ¼(²»¿É¿¿)¡£  
string str = System.IO.Directory.GetCurrentDirectory();  
result: X:\xxx\xxx (.exeÎļþËùÔÚµÄĿ¼) 
//»ñÈ¡µ±Ç°½ø³ÌµÄÍêÕû·¾¶£¬°üº¬ÎļþÃû(½ø³ÌÃû)¡£
string str = this.GetType().Assembly.Location;
result: X:\xxx\xxx\xxx.exe (.exeÎļþËùÔÚµÄĿ¼+.exeÎļþÃû)
//»ñÈ¡Ð嵀 Process ×é¼þ²¢½«ÆäÓ뵱ǰ»î¶¯µÄ½ø³Ì¹ØÁªµÄÖ÷Ä£¿éµÄÍêÕû·¾¶£¬°üº¬ÎļþÃû(½ø³ÌÃû)¡£
string str = System.Diagnostics.Process.GetCurrentPro


Ïà¹ØÎĵµ£º

¼´½«ÍƳöµÄASP.NET Ajax Library...

 ÓкܾÃÒ»¶Îʱ¼äÎÒµÄBLOGÉÏûÓгöÏÖAJAXÏà¹ØÑ¶Ï¢ÁË£¬Ö÷Òªµ±È»ÊÇÒòΪ¾ø´ó²¿·ÖµÄÖØÐͼ·Åµ½ÁËSilverlightÉíÉÏ(¿ÉÔ¤ÆÚµÄδÀ´Ó¦¸ÃÒ²»áÊÇÈç´Ë)¡£
µ«ÓÉÓÚ¹¤×÷ÉϵÄÐèÒª£¬×î½ü»¹ÊÇ»ØÍ·¿´ÁËһϼ´½«ÍƳöµÄASP.NET Ajax Library...£¬Ë³±ãÕÒÁËÒ»ÏÂÍøÂçÉϵÄѶϢ£¬¿´Õâ¸öÌ¬ÊÆÎÒ²ÂÏëÓ¦¸Ã²»ÉÙASP.NET¿ª·¢ÈËÔ±ºöÂÔµôÁËÕâ¸öÆäʵÒѾ­bet ......

c# ref²ÎÊý´«µÝÕæÃæÄ¿

   c#ÖÐÁ½ÖÖ²ÎÊý´«µÝ·½Ê½£¬refºÍ·Çref£¬Ò»Ð©ÈË»á¾õµÃÊÇ·ñ²ÉÓÃref´«µÝ»áÓиü¸ßµÄЧÂÊ£¬Êµ¼ÊÄØ£¿ÏÂÃæ·Ö±ð¿´Ï¡£
   1¡¢ÖµÀàÐͲÎÊývoid FuncA(int iArg1,double dArg1,ref int iArg2,ref double dArg2)¡£
       iArg1ºÍdArg1²»¼Óref£¬´ËʱµÄÈ·»áÔÚÕ»À�±´Ò»·ÝÖµ£¬µ«Í¬Ê ......

asp.netͼƬÑéÖ¤Âë

asp.netϵͳ£¬ÔڵǼ»ò×¢²áʱ³£ÌṩÊý×Ö»ò×Ö·û»ìºÏµÄÑéÖ¤Â룬ÕâÀï½éÉÜÈçºÎ²Ù×÷¡£
1£¬Default Ò³Ãæ
<%@ Page Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script runat="server">
  & ......

C#²Ù×÷AccessÀà Re

using System;
using System.Data;
using System.Data.OleDb;
namespace AccessDb
{
/**//// <summary>
/// AccessDb µÄժҪ˵Ã÷£¬ÒÔÏÂÐÅÏ¢ÇëÍêÕû±£Áô
/// ÇëÔÚÊý¾Ý´«µÝÍê±Ïºóµ÷ÓÃClose()·½·¨£¬¹Ø±ÕÊý¾ÝÁ´½Ó¡£
/// </summary>
public class AccessDbClass
{
±äÁ¿Éù ......

c#ÖжàÏß³Ìͬ²½½â¾ö·½°¸

c#ÖжàÏß³Ìͬ²½½â¾ö·½°¸
C#ÖжÔÓÚ¶àÏ̱߳à³ÌÓкܺõÄÖ§³Ö£¬³£ÓõÄÓÐÒÔϼ¸ÖÖ½â¾ö·½°¸£º
           1. Lock(object) ¶ÔÐèҪͬ²½µÄ´úÂë¿é¼ÓËø£»
¡¡¡¡¡¡¡¡2. Monitor Class
¡¡¡¡¡¡¡¡3. ReaderWriterLock Class¡¡¡¡¡¡
       &nb ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ