65,209
社区成员
发帖
与我相关
我的任务
分享
HWND hwnd = ::FindWindow(_T("NotePad"), _T("无标题 - 记事本")); //同理其他窗口
if (hwnd)
{
LONG style = ::GetWindowLong(hwnd, GWL_STYLE);
style &= ~WS_CAPTION;
style &= ~WS_CLIPSIBLINGS;
style |= WS_CHILD;
::SetWindowLong(hwnd, GWL_STYLE, style);
CRect rc;
GetClientRect(rc);
//rc.bottom -= 60;
//ClientToScreen(&rc);
::SetParent(hwnd, m_hWnd);
::SetWindowPos(hwnd, HWND_TOP, rc.left, rc.top, rc.Width(), rc.Height(), SWP_SHOWWINDOW | SWP_FRAMECHANGED);
//::BringWindowToTop(hwnd);
}

[/quote]
之前在MFC版块别人问过类似问题学习的