• WTL状态栏出现 'CMultiPaneStatusBarCtrl' : missing storageclass or type specifie错误


    WTL状态栏出现 'CMultiPaneStatusBarCtrl' : missing storage-class or type specifie错误

    江西理工  FangSH 2010-8-27

     

    学WTL工具条和状态栏。按例子做了一个Clock3程序 却出现如下的错误:

    WTLClock_Rebar.cpp

    e:\编程文档\wtl\wtl_study_fangsh\wtlclock_rebar\mainfrm.h(62) : error C2146: syntax error : missing ';' before identifier 'm_wndStatusBar'

    e:\编程文档\wtl\wtl_study_fangsh\wtlclock_rebar\mainfrm.h(62) : error C2501: 'CMultiPaneStatusBarCtrl' : missing storage-class or type specifiers

    e:\编程文档\wtl\wtl_study_fangsh\wtlclock_rebar\mainfrm.h(62) : error C2501: 'm_wndStatusBar' : missing storage-class or type specifiers

    aboutdlg.cpp

    mainfrm.cpp

    e:\编程文档\wtl\wtl_study_fangsh\wtlclock_rebar\mainfrm.h(62) : error C2146: syntax error : missing ';' before identifier 'm_wndStatusBar'

    e:\编程文档\wtl\wtl_study_fangsh\wtlclock_rebar\mainfrm.h(62) : error C2501: 'CMultiPaneStatusBarCtrl' : missing storage-class or type specifiers

    e:\编程文档\wtl\wtl_study_fangsh\wtlclock_rebar\mainfrm.h(62) : error C2501: 'm_wndStatusBar' : missing storage-class or type specifiers

    E:\编程文档\WTL\WTL_Study_FangSH\WTLClock_Rebar\mainfrm.cpp(50) : error C2065: 'm_wndStatusBar' : undeclared identifier

    E:\编程文档\WTL\WTL_Study_FangSH\WTLClock_Rebar\mainfrm.cpp(50) : error C2228: left of '.Create' must have class/struct/union type

    E:\编程文档\WTL\WTL_Study_FangSH\WTLClock_Rebar\mainfrm.cpp(56) : error C2228: left of '.SetPanes' must have class/struct/union type

    WTLClock_Rebarview.cpp

    Generating Code...

    主要原因是因为没有定义CmultiPaneStatusBarCtrl所引起的。 仔细检查后发现原来在stdafx.h中没有添加头文件#include <atlctrlx.h> 所致

    atlctrlx.h中可以找到

    class CMultiPaneStatusBarCtrl : public CMultiPaneStatusBarCtrlImpl<CMultiPaneStatusBarCtrl>

    {

    public:

           DECLARE_WND_SUPERCLASS(_T("WTL_MultiPaneStatusBar"), GetWndClassName())

    };

    ――end

  • 相关阅读:
    思岚 激光雷达 A3 使用官方sdk读取数据
    思岚激光雷达 开箱使用
    ubuntu 更新软件失败
    ubuntu 安装tftp
    Ubuntu 安装Telnet服务
    【博客搬至CSDN】
    【RabbitMQ】一文带你搞定springboot整合RabbitMQ涉及消息的发送确认,消息的消费确认机制,延时队列的实现
    基于JVisualVM的可视化监控
    LCN解决分布式事务原理解析+项目实战(原创精华版)
    springboot 用监听器统计在线人数案例分析
  • 原文地址:https://www.cnblogs.com/fangshenghui/p/1810238.html
Copyright © 2020-2023  润新知