Access Function in Child Window From Parent Window
I have a SDI application where my Child is a Listview control. How do I access the listview class from the parent window class? I have tried everything. Messages didn't work, but I may have been doing it wrong.
I am using MFC, VS2008 Pro. And if this helps, here is an example of what I am working with. If you have the new MFC feature pack, create a new project with the Visual Studio interface style, menu bar (not ribbons), single document (sdi), navigation (outlook bar), and the main document is a listview.
What I am trying to do is have a user select a folder in the CMFCShellTreeCtrl (which is part of the parent window/class), then click a button or select a menu item, and call Cmylistview::foo() which is the child.
Please don't flame, I have looked up and down google and have not found anything that answers this question. I am guessing it is a trickier process than simply sending a message which is why I couldn't find an answer.