<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ru">
		<id>http://nfex.ru/index.php?action=history&amp;feed=atom&amp;title=Csharp%2FC_Sharp_by_API%2FSystem.Windows.Forms%2FMouseEventArgs</id>
		<title>Csharp/C Sharp by API/System.Windows.Forms/MouseEventArgs - История изменений</title>
		<link rel="self" type="application/atom+xml" href="http://nfex.ru/index.php?action=history&amp;feed=atom&amp;title=Csharp%2FC_Sharp_by_API%2FSystem.Windows.Forms%2FMouseEventArgs"/>
		<link rel="alternate" type="text/html" href="http://nfex.ru/index.php?title=Csharp/C_Sharp_by_API/System.Windows.Forms/MouseEventArgs&amp;action=history"/>
		<updated>2026-04-30T10:08:01Z</updated>
		<subtitle>История изменений этой страницы в вики</subtitle>
		<generator>MediaWiki 1.30.0</generator>

	<entry>
		<id>http://nfex.ru/index.php?title=Csharp/C_Sharp_by_API/System.Windows.Forms/MouseEventArgs&amp;diff=4092&amp;oldid=prev</id>
		<title> в 15:31, 26 мая 2010</title>
		<link rel="alternate" type="text/html" href="http://nfex.ru/index.php?title=Csharp/C_Sharp_by_API/System.Windows.Forms/MouseEventArgs&amp;diff=4092&amp;oldid=prev"/>
				<updated>2010-05-26T15:31:35Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;ru&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Предыдущая&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Версия 15:31, 26 мая 2010&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; style=&quot;text-align: center;&quot; lang=&quot;ru&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(нет различий)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
			</entry>

	<entry>
		<id>http://nfex.ru/index.php?title=Csharp/C_Sharp_by_API/System.Windows.Forms/MouseEventArgs&amp;diff=4093&amp;oldid=prev</id>
		<title>Admin: 1 версия</title>
		<link rel="alternate" type="text/html" href="http://nfex.ru/index.php?title=Csharp/C_Sharp_by_API/System.Windows.Forms/MouseEventArgs&amp;diff=4093&amp;oldid=prev"/>
				<updated>2010-05-26T12:09:13Z</updated>
		
		<summary type="html">&lt;p&gt;1 версия&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Новая страница&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==MouseEventArgs.Button==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
&amp;lt;source lang=&amp;quot;csharp&amp;quot;&amp;gt; &lt;br /&gt;
using System;&lt;br /&gt;
using System.Collections.Generic;&lt;br /&gt;
using System.ruponentModel;&lt;br /&gt;
using System.Data;&lt;br /&gt;
using System.Drawing;&lt;br /&gt;
using System.Text;&lt;br /&gt;
using System.Windows.Forms;&lt;br /&gt;
public class Form1 : Form&lt;br /&gt;
{&lt;br /&gt;
    private System.Windows.Forms.GroupBox GroupBox1;&lt;br /&gt;
    private System.Windows.Forms.Label Label4;&lt;br /&gt;
    private System.Windows.Forms.Label Label1;&lt;br /&gt;
    private System.Windows.Forms.PictureBox pic;&lt;br /&gt;
    private System.Windows.Forms.TextBox txt;&lt;br /&gt;
    private System.Windows.Forms.Button cmd;&lt;br /&gt;
    private System.Windows.Forms.Label Label2;&lt;br /&gt;
    private System.Windows.Forms.Label Label3;&lt;br /&gt;
    private System.Windows.Forms.ListBox eventLogList;&lt;br /&gt;
    public Form1() {&lt;br /&gt;
        InitializeComponent();&lt;br /&gt;
    }&lt;br /&gt;
    private void Log(String data)&lt;br /&gt;
    {&lt;br /&gt;
        eventLogList.Items.Add(data);&lt;br /&gt;
        int itemsPerPage = (int)(eventLogList.Height / eventLogList.ItemHeight);&lt;br /&gt;
        eventLogList.TopIndex = eventLogList.Items.Count - itemsPerPage;&lt;br /&gt;
    }&lt;br /&gt;
    private void txt_KeyDown(object sender, System.Windows.Forms.KeyEventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Key Down: &amp;quot; + e.KeyCode.ToString() + e.KeyValue.ToString());&lt;br /&gt;
    }&lt;br /&gt;
    private void txt_KeyPress(object sender, System.Windows.Forms.KeyPressEventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Key Press: &amp;quot; + e.KeyChar.ToString());&lt;br /&gt;
    }&lt;br /&gt;
    private void txt_KeyUp(object sender, System.Windows.Forms.KeyEventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Key Up: &amp;quot; + e.KeyCode.ToString() + e.KeyValue.ToString() + &amp;quot; Text is: &amp;quot; + txt.Text);&lt;br /&gt;
    }&lt;br /&gt;
    private void txt_TextChanged(object sender, System.EventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Changed: &amp;quot; + &amp;quot; Text is: &amp;quot; + txt.Text);&lt;br /&gt;
    }&lt;br /&gt;
    private void pic_MouseEnter(object sender, System.EventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Mouse Enter&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    private void pic_MouseHover(object sender, System.EventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Mouse Hover&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    private void pic_MouseDown(object sender, System.Windows.Forms.MouseEventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Mouse Down: X=&amp;quot; + e.X.ToString() + &amp;quot; Y=&amp;quot; + e.Y.ToString() + &amp;quot; Button=&amp;quot; + e.Button.ToString());&lt;br /&gt;
    }&lt;br /&gt;
    private void pic_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Mouse Up: X=&amp;quot; + e.X.ToString() + &amp;quot; Y=&amp;quot; + e.Y.ToString() + &amp;quot; Button=&amp;quot; + e.Button.ToString());&lt;br /&gt;
    }&lt;br /&gt;
    private void pic_Click(object sender, System.EventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Click&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    private void pic_DoubleClick(object sender, System.EventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Double Click&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    private void pic_MouseLeave(object sender, System.EventArgs e)&lt;br /&gt;
    {&lt;br /&gt;
        Log(&amp;quot;Mouse Leave&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    private void InitializeComponent()&lt;br /&gt;
    {&lt;br /&gt;
        this.GroupBox1 = new System.Windows.Forms.GroupBox();&lt;br /&gt;
        this.Label4 = new System.Windows.Forms.Label();&lt;br /&gt;
        this.Label1 = new System.Windows.Forms.Label();&lt;br /&gt;
        this.pic = new System.Windows.Forms.PictureBox();&lt;br /&gt;
        this.txt = new System.Windows.Forms.TextBox();&lt;br /&gt;
        this.cmd = new System.Windows.Forms.Button();&lt;br /&gt;
        this.Label2 = new System.Windows.Forms.Label();&lt;br /&gt;
        this.Label3 = new System.Windows.Forms.Label();&lt;br /&gt;
        this.eventLogList = new System.Windows.Forms.ListBox();&lt;br /&gt;
        this.GroupBox1.SuspendLayout();&lt;br /&gt;
        ((System.ruponentModel.ISupportInitialize)(this.pic)).BeginInit();&lt;br /&gt;
        this.SuspendLayout();&lt;br /&gt;
        // &lt;br /&gt;
        // GroupBox1&lt;br /&gt;
        // &lt;br /&gt;
        this.GroupBox1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)&lt;br /&gt;
                    | System.Windows.Forms.AnchorStyles.Right)));&lt;br /&gt;
        this.GroupBox1.Controls.Add(this.Label4);&lt;br /&gt;
        this.GroupBox1.Controls.Add(this.Label1);&lt;br /&gt;
        this.GroupBox1.Controls.Add(this.pic);&lt;br /&gt;
        this.GroupBox1.Controls.Add(this.txt);&lt;br /&gt;
        this.GroupBox1.Controls.Add(this.cmd);&lt;br /&gt;
        this.GroupBox1.Controls.Add(this.Label2);&lt;br /&gt;
        this.GroupBox1.FlatStyle = System.Windows.Forms.FlatStyle.System;&lt;br /&gt;
        this.GroupBox1.Location = new System.Drawing.Point(7, 0);&lt;br /&gt;
        this.GroupBox1.Name = &amp;quot;GroupBox1&amp;quot;;&lt;br /&gt;
        this.GroupBox1.Size = new System.Drawing.Size(384, 148);&lt;br /&gt;
        this.GroupBox1.TabIndex = 12;&lt;br /&gt;
        this.GroupBox1.TabStop = false;&lt;br /&gt;
        // &lt;br /&gt;
        // Label4&lt;br /&gt;
        // &lt;br /&gt;
        this.Label4.Location = new System.Drawing.Point(92, 108);&lt;br /&gt;
        this.Label4.Name = &amp;quot;Label4&amp;quot;;&lt;br /&gt;
        this.Label4.Size = new System.Drawing.Size(56, 16);&lt;br /&gt;
        this.Label4.TabIndex = 5;&lt;br /&gt;
        this.Label4.Text = &amp;quot;And here:&amp;quot;;&lt;br /&gt;
        // &lt;br /&gt;
        // Label1&lt;br /&gt;
        // &lt;br /&gt;
        this.Label1.Location = new System.Drawing.Point(6, 24);&lt;br /&gt;
        this.Label1.Name = &amp;quot;Label1&amp;quot;;&lt;br /&gt;
        this.Label1.Size = new System.Drawing.Size(144, 16);&lt;br /&gt;
        this.Label1.TabIndex = 2;&lt;br /&gt;
        this.Label1.Text = &amp;quot;Test keyboard events here:&amp;quot;;&lt;br /&gt;
        // &lt;br /&gt;
        // pic&lt;br /&gt;
        // &lt;br /&gt;
        this.pic.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;&lt;br /&gt;
        this.pic.Location = new System.Drawing.Point(156, 48);&lt;br /&gt;
        this.pic.Name = &amp;quot;pic&amp;quot;;&lt;br /&gt;
        this.pic.Size = new System.Drawing.Size(192, 48);&lt;br /&gt;
        this.pic.TabIndex = 3;&lt;br /&gt;
        this.pic.TabStop = false;&lt;br /&gt;
        this.pic.DoubleClick += new System.EventHandler(this.pic_DoubleClick);&lt;br /&gt;
        this.pic.Click += new System.EventHandler(this.pic_Click);&lt;br /&gt;
        this.pic.MouseHover += new System.EventHandler(this.pic_MouseHover);&lt;br /&gt;
        this.pic.MouseUp += new System.Windows.Forms.MouseEventHandler(this.pic_MouseUp);&lt;br /&gt;
        this.pic.MouseEnter += new System.EventHandler(this.pic_MouseEnter);&lt;br /&gt;
        this.pic.MouseDown += new System.Windows.Forms.MouseEventHandler(this.pic_MouseDown);&lt;br /&gt;
        // &lt;br /&gt;
        // txt&lt;br /&gt;
        // &lt;br /&gt;
        this.txt.Location = new System.Drawing.Point(156, 20);&lt;br /&gt;
        this.txt.Name = &amp;quot;txt&amp;quot;;&lt;br /&gt;
        this.txt.Size = new System.Drawing.Size(192, 21);&lt;br /&gt;
        this.txt.TabIndex = 1;&lt;br /&gt;
        this.txt.KeyUp += new System.Windows.Forms.KeyEventHandler(this.txt_KeyUp);&lt;br /&gt;
        this.txt.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txt_KeyPress);&lt;br /&gt;
        this.txt.TextChanged += new System.EventHandler(this.txt_TextChanged);&lt;br /&gt;
        this.txt.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txt_KeyDown);&lt;br /&gt;
        // &lt;br /&gt;
        // cmd&lt;br /&gt;
        // &lt;br /&gt;
        this.cmd.FlatStyle = System.Windows.Forms.FlatStyle.System;&lt;br /&gt;
        this.cmd.Location = new System.Drawing.Point(156, 100);&lt;br /&gt;
        this.cmd.Name = &amp;quot;cmd&amp;quot;;&lt;br /&gt;
        this.cmd.Size = new System.Drawing.Size(88, 28);&lt;br /&gt;
        this.cmd.TabIndex = 4;&lt;br /&gt;
        this.cmd.Text = &amp;quot;Button1&amp;quot;;&lt;br /&gt;
        this.cmd.MouseLeave += new System.EventHandler(this.pic_MouseLeave);&lt;br /&gt;
        this.cmd.Click += new System.EventHandler(this.pic_Click);&lt;br /&gt;
        this.cmd.MouseEnter += new System.EventHandler(this.pic_MouseEnter);&lt;br /&gt;
        this.cmd.MouseHover += new System.EventHandler(this.pic_MouseHover);&lt;br /&gt;
        this.cmd.MouseUp += new System.Windows.Forms.MouseEventHandler(this.pic_MouseUp);&lt;br /&gt;
        this.cmd.MouseDown += new System.Windows.Forms.MouseEventHandler(this.pic_MouseDown);&lt;br /&gt;
        // &lt;br /&gt;
        // Label2&lt;br /&gt;
        // &lt;br /&gt;
        this.Label2.Location = new System.Drawing.Point(20, 52);&lt;br /&gt;
        this.Label2.Name = &amp;quot;Label2&amp;quot;;&lt;br /&gt;
        this.Label2.Size = new System.Drawing.Size(128, 16);&lt;br /&gt;
        this.Label2.TabIndex = 2;&lt;br /&gt;
        this.Label2.Text = &amp;quot;Test mouse events here:&amp;quot;;&lt;br /&gt;
        // &lt;br /&gt;
        // Label3&lt;br /&gt;
        // &lt;br /&gt;
        this.Label3.Location = new System.Drawing.Point(23, 100);&lt;br /&gt;
        this.Label3.Name = &amp;quot;Label3&amp;quot;;&lt;br /&gt;
        this.Label3.Size = new System.Drawing.Size(64, 24);&lt;br /&gt;
        this.Label3.TabIndex = 11;&lt;br /&gt;
        this.Label3.Text = &amp;quot;Label3&amp;quot;;&lt;br /&gt;
        // &lt;br /&gt;
        // eventLogList&lt;br /&gt;
        // &lt;br /&gt;
        this.eventLogList.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)&lt;br /&gt;
                    | System.Windows.Forms.AnchorStyles.Left)&lt;br /&gt;
                    | System.Windows.Forms.AnchorStyles.Right)));&lt;br /&gt;
        this.eventLogList.FormattingEnabled = true;&lt;br /&gt;
        this.eventLogList.IntegralHeight = false;&lt;br /&gt;
        this.eventLogList.Location = new System.Drawing.Point(7, 156);&lt;br /&gt;
        this.eventLogList.Name = &amp;quot;eventLogList&amp;quot;;&lt;br /&gt;
        this.eventLogList.Size = new System.Drawing.Size(384, 212);&lt;br /&gt;
        this.eventLogList.TabIndex = 10;&lt;br /&gt;
        // &lt;br /&gt;
        // Form1&lt;br /&gt;
        // &lt;br /&gt;
        this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);&lt;br /&gt;
        this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;&lt;br /&gt;
        this.ClientSize = new System.Drawing.Size(399, 374);&lt;br /&gt;
        this.Controls.Add(this.GroupBox1);&lt;br /&gt;
        this.Controls.Add(this.Label3);&lt;br /&gt;
        this.Controls.Add(this.eventLogList);&lt;br /&gt;
        this.Font = new System.Drawing.Font(&amp;quot;Tahoma&amp;quot;, 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));&lt;br /&gt;
        this.Name = &amp;quot;Form1&amp;quot;;&lt;br /&gt;
        this.Text = &amp;quot;Event Tracker&amp;quot;;&lt;br /&gt;
        this.GroupBox1.ResumeLayout(false);&lt;br /&gt;
        this.GroupBox1.PerformLayout();&lt;br /&gt;
        ((System.ruponentModel.ISupportInitialize)(this.pic)).EndInit();&lt;br /&gt;
        this.ResumeLayout(false);&lt;br /&gt;
    }&lt;br /&gt;
    [STAThread]&lt;br /&gt;
    static void Main()&lt;br /&gt;
    {&lt;br /&gt;
        Application.EnableVisualStyles();&lt;br /&gt;
        Application.Run(new Form1());&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
           &lt;br /&gt;
   &lt;br /&gt;
  &amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==MouseEventArgs.X==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
&amp;lt;source lang=&amp;quot;csharp&amp;quot;&amp;gt; &lt;br /&gt;
using System; &lt;br /&gt;
using System.Drawing; &lt;br /&gt;
using System.Collections; &lt;br /&gt;
using System.ruponentModel; &lt;br /&gt;
using System.Windows.Forms; &lt;br /&gt;
using System.Data; &lt;br /&gt;
namespace ScreenSave &lt;br /&gt;
{ &lt;br /&gt;
    public class KeyEventandMouseEvent : System.Windows.Forms.Form { &lt;br /&gt;
        private System.Windows.Forms.Label label1; &lt;br /&gt;
        private System.Windows.Forms.Timer timer1; &lt;br /&gt;
        private System.ruponentModel.IContainer components; &lt;br /&gt;
        private Boolean boolFlag; &lt;br /&gt;
        private int ixStart; &lt;br /&gt;
        private int iyStart; &lt;br /&gt;
    &lt;br /&gt;
        public KeyEventandMouseEvent() { &lt;br /&gt;
            // &lt;br /&gt;
            // Required for Windows Form Designer support &lt;br /&gt;
            // &lt;br /&gt;
            InitializeComponent(); &lt;br /&gt;
        } &lt;br /&gt;
        /// &amp;lt;summary&amp;gt; &lt;br /&gt;
        /// Clean up any resources being used. &lt;br /&gt;
        /// &amp;lt;/summary&amp;gt; &lt;br /&gt;
        protected override void Dispose( bool disposing ) &lt;br /&gt;
        { &lt;br /&gt;
            if( disposing ) { &lt;br /&gt;
                if (components != null) &lt;br /&gt;
                { &lt;br /&gt;
                    components.Dispose(); &lt;br /&gt;
                } &lt;br /&gt;
            } &lt;br /&gt;
            base.Dispose( disposing ); &lt;br /&gt;
        } &lt;br /&gt;
        #region Windows Form Designer generated code &lt;br /&gt;
        /// &amp;lt;summary&amp;gt; &lt;br /&gt;
        /// Required method for Designer support - do not modify &lt;br /&gt;
        /// the contents of this method with the code editor. &lt;br /&gt;
        /// &amp;lt;/summary&amp;gt; &lt;br /&gt;
        private void InitializeComponent() { &lt;br /&gt;
            this.ruponents = new System.ruponentModel.Container(); &lt;br /&gt;
            this.timer1 = new System.Windows.Forms.Timer(this.ruponents); &lt;br /&gt;
            this.label1 = new System.Windows.Forms.Label(); &lt;br /&gt;
            this.SuspendLayout(); &lt;br /&gt;
            // &lt;br /&gt;
            // timer1 &lt;br /&gt;
            // &lt;br /&gt;
            this.timer1.Enabled = true; &lt;br /&gt;
            this.timer1.Tick += new System.EventHandler(this.timer1_Tick); &lt;br /&gt;
            // &lt;br /&gt;
            // label1 &lt;br /&gt;
            // &lt;br /&gt;
            this.label1.Font = new System.Drawing.Font(&amp;quot;Times New Roman&amp;quot;, 14F, (System.Drawing.FontStyle.Bold | System.Drawing.FontStyle.Italic), System.Drawing.GraphicsUnit.Point, ((System.Byte)(0))); &lt;br /&gt;
            this.label1.ForeColor = System.Drawing.Color.Lime; &lt;br /&gt;
            this.label1.Location = new System.Drawing.Point(8, 280); &lt;br /&gt;
            this.label1.Name = &amp;quot;label1&amp;quot;; &lt;br /&gt;
            this.label1.Size = new System.Drawing.Size(312, 32); &lt;br /&gt;
            this.label1.TabIndex = 0; &lt;br /&gt;
            this.label1.Text = &amp;quot;Roller - Developed in C-Sharp&amp;quot;; &lt;br /&gt;
            this.label1.Click += new System.EventHandler(this.label1_Click); &lt;br /&gt;
            // &lt;br /&gt;
            // KeyEventandMouseEvent &lt;br /&gt;
            // &lt;br /&gt;
            this.AutoScaleBaseSize = new System.Drawing.Size(5, 13); &lt;br /&gt;
            this.BackColor = System.Drawing.Color.FromArgb(((System.Byte)(64)), ((System.Byte)(64)), ((System.Byte)(64))); &lt;br /&gt;
            this.ClientSize = new System.Drawing.Size(568, 32); &lt;br /&gt;
            this.Controls.AddRange(new System.Windows.Forms.Control[] { &lt;br /&gt;
            this.label1}); &lt;br /&gt;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; &lt;br /&gt;
            this.KeyPreview = true; &lt;br /&gt;
            this.Name = &amp;quot;KeyEventandMouseEvent&amp;quot;; &lt;br /&gt;
            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; &lt;br /&gt;
            this.Text = &amp;quot;KeyEventandMouseEvent&amp;quot;; &lt;br /&gt;
            this.WindowState = System.Windows.Forms.FormWindowState.Maximized; &lt;br /&gt;
            this.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.OnKeyPressEvent); &lt;br /&gt;
            this.Load += new System.EventHandler(this.KeyEventandMouseEvent_Load); &lt;br /&gt;
            this.MouseMove += new System.Windows.Forms.MouseEventHandler(this.OnMouseMoveEvent); &lt;br /&gt;
            this.ResumeLayout(false); &lt;br /&gt;
        } &lt;br /&gt;
        #endregion &lt;br /&gt;
        /// &amp;lt;summary&amp;gt; &lt;br /&gt;
        /// The main entry point for the application. &lt;br /&gt;
        /// &amp;lt;/summary&amp;gt; &lt;br /&gt;
        [STAThread] &lt;br /&gt;
        static void Main() &lt;br /&gt;
        { &lt;br /&gt;
            Application.Run(new KeyEventandMouseEvent()); &lt;br /&gt;
        } &lt;br /&gt;
        private void timer1_Tick(object sender, System.EventArgs e) &lt;br /&gt;
        { &lt;br /&gt;
            int i; &lt;br /&gt;
              &lt;br /&gt;
            i = label1.Location.X; &lt;br /&gt;
            if (i &amp;gt;= 750) &lt;br /&gt;
            i = 0; &lt;br /&gt;
            else &lt;br /&gt;
            i = label1.Location.X + 5; &lt;br /&gt;
              &lt;br /&gt;
            label1.Location = new Point(i,280); &lt;br /&gt;
        } &lt;br /&gt;
        private void KeyEventandMouseEvent_Load(object sender, System.EventArgs e) &lt;br /&gt;
        { &lt;br /&gt;
          &lt;br /&gt;
        } &lt;br /&gt;
        private void OnMouseMoveEvent(object sender,MouseEventArgs e) &lt;br /&gt;
        { &lt;br /&gt;
            //Application.Exit(); &lt;br /&gt;
            if (ixStart == 0 &amp;amp;&amp;amp; iyStart == 0) &lt;br /&gt;
            { &lt;br /&gt;
                ixStart = e.X; &lt;br /&gt;
                iyStart = e.Y; &lt;br /&gt;
            } &lt;br /&gt;
            else if (e.X != ixStart || e.Y != iyStart) &lt;br /&gt;
                Application.Exit(); &lt;br /&gt;
              &lt;br /&gt;
        } &lt;br /&gt;
        private void OnKeyPressEvent(object sender, System.Windows.Forms.KeyPressEventArgs e) &lt;br /&gt;
        { &lt;br /&gt;
            Application.Exit(); &lt;br /&gt;
        } &lt;br /&gt;
        private void label1_Click(object sender, System.EventArgs e) &lt;br /&gt;
        { &lt;br /&gt;
        } &lt;br /&gt;
    } &lt;br /&gt;
} &lt;br /&gt;
 &lt;br /&gt;
   &lt;br /&gt;
  &amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Admin</name></author>	</entry>

	</feed>