Click here to Skip to main content
15,892,161 members
Articles / Desktop Programming / Win32

Spying Window Messages from the Inside

Rate me:
Please Sign up or sign in to vote.
4.94/5 (25 votes)
18 Feb 2009GPL36 min read 108.8K   13.9K   136  
An article on Hooking and Monitoring Window messages
namespace DeviareMsgSpy
{
    partial class HexEdit
    {
        /// <summary>
        /// Required designer variable.
        /// </summary>
        private System.ComponentModel.IContainer components = null;

        /// <summary>
        /// Clean up any resources being used.
        /// </summary>
        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
        protected override void Dispose(bool disposing)
        {
            if (disposing && (components != null))
            {
                components.Dispose();
            }
            base.Dispose(disposing);
        }

        #region Windows Form Designer generated code

        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            this.msgNmeLbl = new System.Windows.Forms.Label();
            this.MsgName = new System.Windows.Forms.TextBox();
            this.HexAddrLbl = new System.Windows.Forms.Label();
            this.hexAddr = new System.Windows.Forms.TextBox();
            this.LParam = new System.Windows.Forms.TextBox();
            this.label2 = new System.Windows.Forms.Label();
            this.WParam = new System.Windows.Forms.TextBox();
            this.submitMsg = new System.Windows.Forms.Button();
            this.label3 = new System.Windows.Forms.Label();
            this.label1 = new System.Windows.Forms.Label();
            this._wParamType = new System.Windows.Forms.TextBox();
            this.label4 = new System.Windows.Forms.Label();
            this._lParamType = new System.Windows.Forms.TextBox();
            this.label5 = new System.Windows.Forms.Label();
            this._wParamMiscBox = new System.Windows.Forms.TextBox();
            this._lParamMiscBox = new System.Windows.Forms.TextBox();
            this.label6 = new System.Windows.Forms.Label();
            this.label7 = new System.Windows.Forms.Label();
            this._returnInfoBox = new System.Windows.Forms.TextBox();
            this._returnTypeBox = new System.Windows.Forms.TextBox();
            this.label8 = new System.Windows.Forms.Label();
            this._returnMiscBox = new System.Windows.Forms.TextBox();
            this.label9 = new System.Windows.Forms.Label();
            this._miscBox = new System.Windows.Forms.TextBox();
            this.label10 = new System.Windows.Forms.Label();
            this.SuspendLayout();
            // 
            // msgNmeLbl
            // 
            this.msgNmeLbl.AutoSize = true;
            this.msgNmeLbl.Location = new System.Drawing.Point(13, 11);
            this.msgNmeLbl.Name = "msgNmeLbl";
            this.msgNmeLbl.Size = new System.Drawing.Size(81, 13);
            this.msgNmeLbl.TabIndex = 0;
            this.msgNmeLbl.Text = "Message Name";
            // 
            // MsgName
            // 
            this.MsgName.Location = new System.Drawing.Point(16, 28);
            this.MsgName.Name = "MsgName";
            this.MsgName.Size = new System.Drawing.Size(316, 20);
            this.MsgName.TabIndex = 1;
            // 
            // HexAddrLbl
            // 
            this.HexAddrLbl.AutoSize = true;
            this.HexAddrLbl.Location = new System.Drawing.Point(13, 51);
            this.HexAddrLbl.Name = "HexAddrLbl";
            this.HexAddrLbl.Size = new System.Drawing.Size(113, 13);
            this.HexAddrLbl.TabIndex = 2;
            this.HexAddrLbl.Text = "Message Hex Address";
            // 
            // hexAddr
            // 
            this.hexAddr.Location = new System.Drawing.Point(16, 67);
            this.hexAddr.Name = "hexAddr";
            this.hexAddr.ReadOnly = true;
            this.hexAddr.Size = new System.Drawing.Size(316, 20);
            this.hexAddr.TabIndex = 3;
            // 
            // LParam
            // 
            this.LParam.Location = new System.Drawing.Point(16, 275);
            this.LParam.Name = "LParam";
            this.LParam.Size = new System.Drawing.Size(316, 20);
            this.LParam.TabIndex = 5;
            // 
            // label2
            // 
            this.label2.AutoSize = true;
            this.label2.Location = new System.Drawing.Point(13, 90);
            this.label2.Name = "label2";
            this.label2.Size = new System.Drawing.Size(45, 13);
            this.label2.TabIndex = 6;
            this.label2.Text = "wParam";
            // 
            // WParam
            // 
            this.WParam.Location = new System.Drawing.Point(16, 106);
            this.WParam.Name = "WParam";
            this.WParam.Size = new System.Drawing.Size(316, 20);
            this.WParam.TabIndex = 7;
            // 
            // submitMsg
            // 
            this.submitMsg.Location = new System.Drawing.Point(16, 443);
            this.submitMsg.Name = "submitMsg";
            this.submitMsg.Size = new System.Drawing.Size(75, 23);
            this.submitMsg.TabIndex = 8;
            this.submitMsg.Text = "Submit";
            this.submitMsg.UseVisualStyleBackColor = true;
            this.submitMsg.Click += new System.EventHandler(this.submitMsg_Click);
            // 
            // label3
            // 
            this.label3.AutoSize = true;
            this.label3.Location = new System.Drawing.Point(13, 259);
            this.label3.Name = "label3";
            this.label3.Size = new System.Drawing.Size(39, 13);
            this.label3.TabIndex = 4;
            this.label3.Text = "lParam";
            // 
            // label1
            // 
            this.label1.AutoSize = true;
            this.label1.Location = new System.Drawing.Point(13, 129);
            this.label1.Name = "label1";
            this.label1.Size = new System.Drawing.Size(72, 13);
            this.label1.TabIndex = 9;
            this.label1.Text = "wParam Type";
            // 
            // _wParamType
            // 
            this._wParamType.Location = new System.Drawing.Point(16, 145);
            this._wParamType.Name = "_wParamType";
            this._wParamType.Size = new System.Drawing.Size(316, 20);
            this._wParamType.TabIndex = 10;
            // 
            // label4
            // 
            this.label4.AutoSize = true;
            this.label4.Location = new System.Drawing.Point(13, 298);
            this.label4.Name = "label4";
            this.label4.Size = new System.Drawing.Size(66, 13);
            this.label4.TabIndex = 11;
            this.label4.Text = "lParam Type";
            // 
            // _lParamType
            // 
            this._lParamType.Location = new System.Drawing.Point(16, 314);
            this._lParamType.Name = "_lParamType";
            this._lParamType.Size = new System.Drawing.Size(316, 20);
            this._lParamType.TabIndex = 12;
            // 
            // label5
            // 
            this.label5.AutoSize = true;
            this.label5.Location = new System.Drawing.Point(13, 168);
            this.label5.Name = "label5";
            this.label5.Size = new System.Drawing.Size(69, 13);
            this.label5.TabIndex = 13;
            this.label5.Text = "wParam misc";
            // 
            // _wParamMiscBox
            // 
            this._wParamMiscBox.Location = new System.Drawing.Point(16, 184);
            this._wParamMiscBox.Multiline = true;
            this._wParamMiscBox.Name = "_wParamMiscBox";
            this._wParamMiscBox.ScrollBars = System.Windows.Forms.ScrollBars.Both;
            this._wParamMiscBox.Size = new System.Drawing.Size(316, 72);
            this._wParamMiscBox.TabIndex = 14;
            // 
            // _lParamMiscBox
            // 
            this._lParamMiscBox.Location = new System.Drawing.Point(16, 353);
            this._lParamMiscBox.Multiline = true;
            this._lParamMiscBox.Name = "_lParamMiscBox";
            this._lParamMiscBox.ScrollBars = System.Windows.Forms.ScrollBars.Both;
            this._lParamMiscBox.Size = new System.Drawing.Size(316, 72);
            this._lParamMiscBox.TabIndex = 16;
            // 
            // label6
            // 
            this.label6.AutoSize = true;
            this.label6.Location = new System.Drawing.Point(13, 337);
            this.label6.Name = "label6";
            this.label6.Size = new System.Drawing.Size(63, 13);
            this.label6.TabIndex = 15;
            this.label6.Text = "lParam misc";
            // 
            // label7
            // 
            this.label7.AutoSize = true;
            this.label7.Location = new System.Drawing.Point(363, 11);
            this.label7.Name = "label7";
            this.label7.Size = new System.Drawing.Size(60, 13);
            this.label7.TabIndex = 17;
            this.label7.Text = "Return Info";
            // 
            // _returnInfoBox
            // 
            this._returnInfoBox.Location = new System.Drawing.Point(366, 28);
            this._returnInfoBox.Name = "_returnInfoBox";
            this._returnInfoBox.Size = new System.Drawing.Size(333, 20);
            this._returnInfoBox.TabIndex = 18;
            // 
            // _returnTypeBox
            // 
            this._returnTypeBox.Location = new System.Drawing.Point(366, 67);
            this._returnTypeBox.Name = "_returnTypeBox";
            this._returnTypeBox.Size = new System.Drawing.Size(333, 20);
            this._returnTypeBox.TabIndex = 20;
            // 
            // label8
            // 
            this.label8.AutoSize = true;
            this.label8.Location = new System.Drawing.Point(363, 50);
            this.label8.Name = "label8";
            this.label8.Size = new System.Drawing.Size(66, 13);
            this.label8.TabIndex = 19;
            this.label8.Text = "Return Type";
            // 
            // _returnMiscBox
            // 
            this._returnMiscBox.Location = new System.Drawing.Point(366, 106);
            this._returnMiscBox.Multiline = true;
            this._returnMiscBox.Name = "_returnMiscBox";
            this._returnMiscBox.ScrollBars = System.Windows.Forms.ScrollBars.Both;
            this._returnMiscBox.Size = new System.Drawing.Size(333, 59);
            this._returnMiscBox.TabIndex = 22;
            // 
            // label9
            // 
            this.label9.AutoSize = true;
            this.label9.Location = new System.Drawing.Point(363, 89);
            this.label9.Name = "label9";
            this.label9.Size = new System.Drawing.Size(63, 13);
            this.label9.TabIndex = 21;
            this.label9.Text = "Return misc";
            // 
            // _miscBox
            // 
            this._miscBox.Location = new System.Drawing.Point(366, 185);
            this._miscBox.Multiline = true;
            this._miscBox.Name = "_miscBox";
            this._miscBox.ScrollBars = System.Windows.Forms.ScrollBars.Both;
            this._miscBox.Size = new System.Drawing.Size(333, 240);
            this._miscBox.TabIndex = 24;
            // 
            // label10
            // 
            this.label10.AutoSize = true;
            this.label10.Location = new System.Drawing.Point(363, 168);
            this.label10.Name = "label10";
            this.label10.Size = new System.Drawing.Size(28, 13);
            this.label10.TabIndex = 23;
            this.label10.Text = "misc";
            // 
            // HexEdit
            // 
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.ClientSize = new System.Drawing.Size(711, 487);
            this.Controls.Add(this._miscBox);
            this.Controls.Add(this.label10);
            this.Controls.Add(this._returnMiscBox);
            this.Controls.Add(this.label9);
            this.Controls.Add(this._returnTypeBox);
            this.Controls.Add(this.label8);
            this.Controls.Add(this._returnInfoBox);
            this.Controls.Add(this.label7);
            this.Controls.Add(this._lParamMiscBox);
            this.Controls.Add(this.label6);
            this.Controls.Add(this._wParamMiscBox);
            this.Controls.Add(this.label5);
            this.Controls.Add(this._lParamType);
            this.Controls.Add(this.label4);
            this.Controls.Add(this._wParamType);
            this.Controls.Add(this.label1);
            this.Controls.Add(this.submitMsg);
            this.Controls.Add(this.WParam);
            this.Controls.Add(this.label2);
            this.Controls.Add(this.LParam);
            this.Controls.Add(this.label3);
            this.Controls.Add(this.hexAddr);
            this.Controls.Add(this.HexAddrLbl);
            this.Controls.Add(this.MsgName);
            this.Controls.Add(this.msgNmeLbl);
            this.Name = "HexEdit";
            this.Text = "Edit Msg";
            this.ResumeLayout(false);
            this.PerformLayout();

        }

        #endregion

        private System.Windows.Forms.Label msgNmeLbl;
        private System.Windows.Forms.TextBox MsgName;
        private System.Windows.Forms.Label HexAddrLbl;
        private System.Windows.Forms.TextBox hexAddr;
        private System.Windows.Forms.TextBox LParam;
        private System.Windows.Forms.Label label2;
        private System.Windows.Forms.TextBox WParam;
        private System.Windows.Forms.Button submitMsg;
        private System.Windows.Forms.Label label3;
        private System.Windows.Forms.Label label1;
        private System.Windows.Forms.TextBox _wParamType;
        private System.Windows.Forms.Label label4;
        private System.Windows.Forms.TextBox _lParamType;
        private System.Windows.Forms.Label label5;
        private System.Windows.Forms.TextBox _wParamMiscBox;
        private System.Windows.Forms.TextBox _lParamMiscBox;
        private System.Windows.Forms.Label label6;
        private System.Windows.Forms.Label label7;
        private System.Windows.Forms.TextBox _returnInfoBox;
        private System.Windows.Forms.TextBox _returnTypeBox;
        private System.Windows.Forms.Label label8;
        private System.Windows.Forms.TextBox _returnMiscBox;
        private System.Windows.Forms.Label label9;
        private System.Windows.Forms.TextBox _miscBox;
        private System.Windows.Forms.Label label10;

    }
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The GNU General Public License (GPLv3)


Written By
Software Developer
Argentina Argentina
C/C++ developer interested on operating systems, reverse engineering, general system programming, CPU architecture, etc.
Now I'm working creating plugins Outlook Plugin Development.

Comments and Discussions