zhekha В ресурсах пропиши класс:
| Код | IDD_MY_DIALOG DIALOGEX 0, 0, 200, 67 STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU EXSTYLE WS_EX_TOOLWINDOW | WS_EX_APPWINDOW CAPTION "My Dialog" CLASS "MyDialogClass" FONT 8, "MS Shell Dlg", 0, 0, 0x1 BEGIN ...
|
А в CMyApp::InitInstance() перед созданием диалога добавь следующий код:
| Код | WNDCLASS wc;
// Get the info for this class. // #32770 is the default class name for dialogs boxes. ::GetClassInfo(AfxGetInstanceHandle(), "#32770", &wc);
// Change the name of the class. wc.lpszClassName = "MyDialogClass";
// Register this class so that MFC can use it. AfxRegisterClass(&wc);
|
|