Snoop 64 bit

I can't really take much credit for this because I didn't do that much work for it, but here is a link to his post on 64 bit snoop.  You can thank my coworker Dan for 99% of this.

If you are doing any WPF development, you NEED this tool.  Dan has taken the time to throw some pretty nice additions into this version of the tool, so even if you already using snoop, you should take a look at his modified version.

Happy snooping!

Share this post!

2 comments:

Wolf said...

I've created my own 64bit version (here's the post i'm reproducing across the internets):
---------
I got it to work on x64 windows 7. (Wow took me like 10 seconds to figure out the problem).

First, you can just download the version i got to work (it'll probably work both on 32 bit and 64 bit but only 64 bit is tested ok)
http://wolfsfiles.googlepages.com/Snoop.rar

Then you can either build the heck out of it, or you can just run the installer located in this subfolder: Build > Release > Installer.msi

I installed it. I tested it to watch Blend3 peel away into 3D layers of eye-candyness... it works... ON 64 BIT!! :P

------------------

This is the modifications i did to the original source which can be downloaded from this website: http://www.blois.us/Snoop/


1. I extract the contents of Snoop.zip to a folder. And open the solution with visual studio.

2. "Warning for Snoop" pops up because the project specifies some custom build path for output files or something. Choose "Load project normally" and hit OK.

3. ManagedInjector needs some small code modifications:

--------------------------------

In the project "ManagedInjector", open the headerfile: "Injector.h"

Change this line so the return from this function is "LRESULT": "int __stdcall MessageHookProc(int nCode, WPARAM wparam, LPARAM lparam);"

You should now have: "LRESULT __stdcall MessageHookProc(int nCode, WPARAM wparam, LPARAM lparam);"

-------------------------------

In the project "ManagedInjector", open the headerfile: "Injector.cpp"

Change this line so the return from this function is "LRESULT": "int __stdcall MessageHookProc(int nCode, WPARAM wparam, LPARAM lparam) {"

You should now have "LRESULT __stdcall MessageHookProc(int nCode, WPARAM wparam, LPARAM lparam) {"

-------------------------------

4. Build ManagedInjector. Build Snoop. Build Installer. (just doing a rebuild-all might or might not work... check the build order... but doing it one at a time is guarenteed to work if done in the specified order)

5. Might need to set Snoop as the startup project (if you want to just run it from visual studio, without installing).

Wolf said...

P.s. If you download my version, it incorporates the snoop fixes listed on these websites:
http://www.cplotts.com/2009/04/04/snoop-20-now-works-in-wpf-interop-scenarios/
http://www.cplotts.com/2009/04/13/snoop-now-works-in-wpf-interop-scenarios-part-ii/
I'm not sure the effects of those fixes but they couldn't hurt... i marked those changes in the source... just look for those web-addresses in the solution to see where the changes were.

Post a Comment