CLASS Statement
The CLASS resource-definition statement sets the class of the dialog box...........
 
CLASS class
class
A 16-bit unsigned integer or a string, enclosed in double quotation s ("), that identifies the class of the dialog box. If the window procedure for the class does not process a message sent to it, it must call the DefDlgProc function to ensure that all messages are handled properly for the dialog box. A private class can use DefDlgProc as the default window procedure. The class must be registered with the cbWndExtra member of the WNDCLASS structure set to DLGWINDOWEXTRA. 
............ExampleThe following example demonstrates the use of the CLASS statement:
CLASS "myclass" 请帮翻译上面两个省略号中的内容,它来字MSDN在线,我正准备着手开始C语言学习,但是找不到中文资料。
我初略翻译了一下,它说该类的窗口过程不处理发来的消息是不是指当前这个类的窗口,还是被勾了类的所有拥有该类的窗口?
实际测试中,在对话框的过程中DefDlgPro函数一使用就失败。我的测试方法是:在VB下调用dll的对话框资源。
是否存在中文版的MSDN C 和 C++ 的内容,便于学习C和C++。谢谢了。
40分够了吧,不够再加。

解决方案 »

  1.   

    当然有中文版的MSDN了,你到迅雷一搜就得。A 16-bit unsigned integer or a string, enclosed in double quotation s ("), that identifies the class of the dialog box. If the window procedure for the class does not process a message sent to it, it must call the DefDlgProc function to ensure that all messages are handled properly for the dialog box. A private class can use DefDlgProc as the default window procedure. The class must be registered with the cbWndExtra member of the WNDCLASS structure set to DLGWINDOWEXTRA. class是一个16位无符号整形或字符串,以双引号括着,表示对话框对应的类。
    如果该类的窗口过程不处理发给它的消息,那它必须调用DefDlgProc 函数以确保发给这个对话框的所有消息都被妥善处理了。
    私有类可以用DefDlgProc 作为其缺省的窗口过程。这时要把WNDCLASS 结构中的cbWndExtra 成员设置为DLGWINDOWEXTRA。
      

  2.   


    你是如何调用DefDlgPro这个函数的?这是一个回调函数。
      

  3.   

    经典WIN32下的回调,WndProc是自己的消息处理函数(回调函数),DefDlgProc是系统默认的消息处理函数(回调函数),如下:
    LRESULT CALLBACK WndProc(HWND hwnd,UINT message,WPARAM wParam,LPARAM lParam){
    switch(message){
    case WM_DESTROY:
    PostQuitMessage(0);
    return 0;
    }
    return DefDlgProc(hwnd,message,wParam,lParam);
    }
      

  4.   

    Class语句 
    在类资源的定义语句设置对话框的类。 .......... 类级 
    类 
    一个16位的无符号整数或一个字符串,用双引号(“),标识对话框的类。若该类的窗口过程不处理消息发送给它,它必须调用DefDlgProc函数以确保所有邮件的处理对话框的正确。私人类可以使用默认的窗口过程DefDlgProc。类必须是登记了一套DLGWINDOWEXTRA WNDCLASS结构cbWndExtra成员。 
    ............ 例如 下面的例子演示了类语句的使用: 
    类“MyClass的”