开发者

Loop through MFC Child Dialogs, MDIFrames etc

开发者 https://www.devze.com 2022-12-12 12:23 出处:网络
Is there a way to loop through all MFC Child Dialogs, MDI frames 开发者_运维百科and etc? And is there a way to find out which dialog or window I am looping through?Taken from Анатолий Туто

Is there a way to loop through all MFC Child Dialogs, MDI frames 开发者_运维百科and etc? And is there a way to find out which dialog or window I am looping through?


Taken from Анатолий Тутов (https://web.archive.org/web/20140110220804/http://www.asis.ru/posts/27):

for (CWnd *pWnd = GetWindow(GW_CHILD);  pWnd != NULL;  pWnd = pWnd->GetNextWindow(GW_HWNDNEXT))
{
    //Insert your code here. pWnd is a pointer to control window.
}


You could use EnumChildWindows to iterate through child windows of certain window.

0

精彩评论

暂无评论...
验证码 换一张
取 消