C#»Ï߿ؼþµÄ¿ª·¢Ó¦ÓÃʵÀý½âÎö
C#»Ï߿ؼþµÄÓ¦ÓÃʵÀý½éÉÜ֮ǰÎÒÃÇÒªÃ÷°×ÔÚC#ÖÐûÓлÏߵĿؼþ£¬ÕâÀïдÁËÒ»¸ö£¬´ó¼Ò·ÖÏí¡£¹²ÓÐÁ½¸ö¿Ø¼þ·Ö±ðÊÇ»ºáÏߺͻÊúÏߵģ¬¹ØÓÚÔõô»Ð±ÏßÓÐÐËȤµÄ¿ÉÒÔ×öÒ»¸ö´ó¼Ò·ÖÏí¡£
C#»Ï߿ؼþÖ®ºáÏß
using System;
using System.Collections;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Windows.Forms;
namespace Jiashi.WinControls
{
///
/// LineX »ºáÏ߿ؼþ
///
public class LineX : System.Windows.Forms.UserControl
{
#region ÊôÐÔ¶¨Òå
private System.Drawing.Color lineColor;
private int lineWidth;
///
/// ÏßµÄÑÕÉ«ÊôÐÔ
///
public System.Drawing.Color LineColor
{
set
{
this.lineColor=value;
System.Windows.Forms.PaintEventArgs ep=
new PaintEventArgs(this.CreateGraphics(),
this.ClientRectangle);
this.LineX_Paint(this,ep);
}
get{return this.lineColor;}
}
///
/// ÏߵĴÖϸ
///
public int LineWidth
{
set
{
this.lineWidth=value;
System.Windows.Forms.PaintEventArgs ep=
new PaintEventArgs(this.CreateGraphics(),
this.ClientRectangle);
this.LineX_Paint(this,ep);
}
get{return this.lineWidth;}
}
#endregion
private System.ComponentModel.Container components = null;
///
/// ¹¹Ô캯Êý³õʼÑÕÉ«ºÍÏß´Öϸ
///
public LineX()
{
InitializeComponent();
this.lineColor=this.ForeColor;
this.lin
Ïà¹ØÎĵµ£º
±äÁ¿¡¢³£Á¿¼°±í´ïʽ±äÁ¿ºÍ³£Á¿±äÁ¿(¾²Ì¬¡¢·Ç¾²Ì¬¡¢Êý×éÔªËØ¡¢Öµ²ÎÊý¡¢ÒýÓòÎÊý¡¢Êä³ö²ÎÊý¡¢¾Ö²¿±äÁ¿)¾²Ì¬(static) Èç public static int x; Ò»µ©¾²Ì¬±äÁ¿ËùÊôµÄÀà±»×°ÔØ£¬Ö±µ½°üº¬¸ÃÀàµÄ³ÌÐòÔËÐнáÊøʱËüÒ»Ö±´æÔÚ¡£·Ç¾²Ì¬£º²»´øÓÐstaticÐÞÊηûÉùÃ÷µÄ±äÁ¿³ÆΪʵÀý±äÁ¿£¬Èçint a ;³£Á¿(attributes constnt-modifiers CO ......
תÒåÐòÁÐ ×Ö·ûÃû³Æ Unicode ±àÂë
\' µ¥ÒýºÅ 0x0027
\" Ë«Òýº ......
C#Çå³ýÒ³Ã滺´æ
private void SetPageNoCache()
{
Response.Buffer = true;
Response.ExpiresAbsolute = Sy ......
C:\ProgramFiles\MicrosoftVisual Studio .NET\ FrameworkSDK\Samples\ Technologies\ Interop\PlatformInvoke\ WinAPIs\CSĿ¼ÏÂÓдóÁ¿µÄµ÷ÓÃAPIµÄÀý×Ó¡£
Ò»¡¢µ÷Óøñʽ
using System.Runtime.InteropServices; //ÒýÓôËÃû³Æ¿Õ¼ä£¬¼ò»¯ºóÃæµÄ´úÂë
//ʹÓÃDllImportAttributeÌØÐÔÀ´ÒýÈëapiº¯Êý£¬×¢ÒâÉùÃ÷µÄÊÇ¿Õ·½·¨£¬¼´·½· ......
ü ref¡¢out¡¢Óëparams
Ó¦¸ÃÀ´ËµÕâÈý¸ö¹Ø¼üÔÚÒ»°ãµÄ±àÂë¹ý³ÌÖл¹Êǻ᲻ʱÉæ¼°µ½µÄ£¬ËùÒÔ²»Ëãʲô“ÀäƧ”µÄ¸ÅÄî¡£ÓйØÈý¸ö²ÎÊýÐÞÊηûµÄ½âÊÍÈçÏ£º
Ref£ºref¹Ø¼ü×ÖÈÃÒ»¸öÖµÀàÐ͵ÄÊäÈë²ÎÊý°´ÒýÓô«µÝ¡£Êµ¼ÊÉÏ£¬¶ÔÓÚÒýÓÃÀàÐ͵IJÎÊý£¬ÊÇ·ñʹÓÃref¹Ø¼ü×Ö£¬²î±ð΢ºõÆä΢¡£ÓÐÒ»¸öÀýÍâÊÇStringÀàÐ͵IJΠ......