This project has moved and is read-only. For the latest updates, please go here.

Love the App. New to WPF. Need Help.

Aug 8, 2013 at 9:35 PM
Hey there, love the app. I have some questions though. I am trying to implement a simple application that only finds a specific wpf window and get controls from it based on either the name or classname. I have looked over the source code of your app, but I am more proficient in VB and kind of rusty in C++ and C#. I have spent a week trying to figure out how to get it to work and am still having trouble trying to piece it together. I am starting to get relatively frustrated because I'm sure the answer is simple. If there's any way I could get some help, I would greatly appreciate it.
Aug 13, 2013 at 7:34 PM
Hi beastmp,

The way Snoop works is that it injects itself into the application being snooped. That means that the Snoop code runs inside the application being snooped. It runs as part of the program being snooped. Therefore, after the injection is done, to do what you want you would have to have snoop pass messages between the program being snooped and the application requesting details about the controls.

So if you're debugging Snoop and stepping through the source code, you would attach your Visual Studio debugger to the application being snooped, not Snoop itself.

Aug 13, 2013 at 9:00 PM
I think I understand. That's what the C++ ManagedInjector is for? I forgot to mention that this is an external application that I am unable to modify the source code or attach my debugger to.
I've been able to read and understand more of the code since I made my first post, but I'm still having trouble understanding how it retrieves the root visual item from the window object. I feel that if I could just make that connection, I would be able to piece the rest of it together.