Solved

What is the WPF Equivalent to overriding the WndProc event

Posted on 2008-06-23
2
2,487 Views
Last Modified: 2013-12-16
I am trying to move some custom control library applications over to WPF. In one application in particular it is critical that i can trap for the following events that occur on the control. I am having trouble trapping for the windows messages, because the namespaces do not exist in wpf. What can i do to mimic this functionality in WPF?

Thanks in advance.

   Protected Overrides Sub WndProc(ByRef m As System.Windows.Forms.Message)
        Select Case m.Msg
            Case WM_MOVING
            Case WM_LBUTTONDBLCLK
            Case WM_LBUTTONDOWN    
            Case WM_LBUTTONUP
            Case WM_MOUSEACTIVATE
            Case WM_ACTIVATE
            Case WM_MOUSELEAVE
            Case Else
        End Select
        MyBase.WndProc(m)
    End Sub
0
Comment
Question by:talker2004
2 Comments
 
LVL 16

Accepted Solution

by:
CuteBug earned 500 total points
ID: 21854034
0
 
LVL 7

Author Comment

by:talker2004
ID: 21865699
This is exctly the type of stuff i am looking for.

Thanks

0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Welcome my friends to the second instalment and follow-up to our Minify and Concatenate Your Scripts and Stylesheets (http://www.experts-exchange.com/Programming/Languages/.NET/ASP.NET/A_4334-Minify-and-Concatenate-Your-Scripts-and-Stylesheets.html)…
In my previous two articles we discussed Binary Serialization (http://www.experts-exchange.com/A_4362.html) and XML Serialization (http://www.experts-exchange.com/A_4425.html). In this article we will try to know more about SOAP (Simple Object Acces…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

822 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question