How to get active child frame from main frame?
MDIGetActive method gets you the HWND you need.
MDIGetActive
HWND