M
Michael Culley
I've added an IMessageFilter to my app but I don't get messages or I get only a few and then it stops. My code is very simple. Am I
doing something wrong?
public class MF : IMessageFilter
{
public MF()
{
}
public bool PreFilterMessage(ref Message m)
{
if(m.Msg == 15)
{
Console.WriteLine("Paint");
}
return false;
}
}
and
Application.AddMessageFilter(new MF());
I've tried putting this in different locations, such as void Main, Form_Load etc
doing something wrong?
public class MF : IMessageFilter
{
public MF()
{
}
public bool PreFilterMessage(ref Message m)
{
if(m.Msg == 15)
{
Console.WriteLine("Paint");
}
return false;
}
}
and
Application.AddMessageFilter(new MF());
I've tried putting this in different locations, such as void Main, Form_Load etc