using System;
using System.Windows.Forms;
namespace WindowsApplication1 {
public partial class Form1 : Form, IMessageFilter {
public Form1() {
InitializeComponent();
Application.AddMessageFilter(this);
this.FormClosed += new FormClosedEventHandler(this.Form1_FormClosed);
}
private void Form1_FormClosed(object sender, FormClosedEventArgs e) {
Application.RemoveMessageFilter(this);
}
public bool PreFilterMessage(ref Message m) {
// Filter out WM_NCRBUTTONDOWN/UP/DBLCLK
if (m.Msg == 0xA4 || m.Msg == 0xA5 || m.Msg == 0xA6) return true;
// Filter out WM_RBUTTONDOWN/UP/DBLCLK
if (m.Msg == 0x204 || m.Msg == 0x205 || m.Msg == 0x206) return true;
return false;
}
}
}
C# OutLook AttachFile Drop&Drop (0) | 2013.04.22 |
---|---|
Keyboard Hooking (0) | 2013.04.17 |
TableLayoutPanel Position 얻기 (0) | 2013.04.16 |
코드로 관리자 권한 상승 시키기 (0) | 2013.03.29 |
Binary File Read & Write (0) | 2013.03.27 |