• 最新版Duilib在VS2012下编译错误的解决方法


            svn了好几次最新版本的项目源代码, 在VS2012下编译老是出错, 改了后没记录, 结果又忘记, 所以在此记录下.

           这个问题很普遍, 非常多的人遇到.

          至于其它的示例Demo的错误则简单修改项目属性即可.

     

           好了,错误描述就像下面这样:

    1>------ Build started: Project: DuiLib, Configuration: UnicodeDebug Win32 ------
    1>  StdAfx.cpp
    1>c:usersyangtaodesktop ew folderduilibControl/UIFlash.h(10): warning C4192: automatically excluding 'IServiceProvider' while importing type library '..Utils/Flash11.tlb'
    1>  UIWebBrowser.cpp
    1>c:program fileswindows kits8.0includeumdispex.h(228): error C2371: 'IDispatchEx' : redefinition; different basic types
    1>          c:program fileswindows kits8.0includeumdispex.h(45) : see declaration of 'IDispatchEx'
    1>c:program fileswindows kits8.0includeumdispex.h(455): error C2872: 'IDispatchEx' : ambiguous symbol
    1>          could be 'c:program fileswindows kits8.0includeumdispex.h(228) : IDispatchEx'
    1>          or       'c:usersyangtaodesktop ew folderduilibuilddebug_uflash11.tlh(297) : ShockwaveFlashObjects::IDispatchEx'
    1>c:program fileswindows kits8.0includeumdispex.h(791): error C2371: 'ICanHandleException' : redefinition; different basic types
    1>          c:program fileswindows kits8.0includeumdispex.h(73) : see declaration of 'ICanHandleException'
    1>c:program fileswindows kits8.0includeumdispex.h(977): error C2872: 'IDispatchEx' : ambiguous symbol
    1>          could be 'c:program fileswindows kits8.0includeumdispex.h(228) : IDispatchEx'
    1>          or       'c:usersyangtaodesktop ew folderduilibuilddebug_uflash11.tlh(297) : ShockwaveFlashObjects::IDispatchEx'
    1>c:program fileswindows kits8.0includeumdispex.h(995): error C2872: 'IDispatchEx' : ambiguous symbol
    1>          could be 'c:program fileswindows kits8.0includeumdispex.h(228) : IDispatchEx'
    1>          or       'c:usersyangtaodesktop ew folderduilibuilddebug_uflash11.tlh(297) : ShockwaveFlashObjects::IDispatchEx'
    1>C:Program FilesWindows Kits8.0Includeummshtml.h(9754): error C2872: 'IDispatchEx' : ambiguous symbol
    1>          could be 'c:program fileswindows kits8.0includeumdispex.h(228) : IDispatchEx'
    1>          or       'c:usersyangtaodesktop ew folderduilibuilddebug_uflash11.tlh(297) : ShockwaveFlashObjects::IDispatchEx'
    1>C:Program FilesWindows Kits8.0Includeummshtml.h(9778): error C2872: 'IDispatchEx' : ambiguous symbol
    1>          could be 'c:program fileswindows kits8.0includeumdispex.h(228) : IDispatchEx'
    1>          or       'c:usersyangtaodesktop ew folderduilibuilddebug_uflash11.tlh(297) : ShockwaveFlashObjects::IDispatchEx'

    Duilib编译出错

     

    解决方案:

    修改UIWebBrowser.cpp和UIWebBrowser.h:

    修改前:

    修改前

    修改后:

    修改后

     

    女孩不哭 @ cnblogs.com/memset @ 2014-05-11

  • 相关阅读:
    windows窗体中的一些事。。。
    数据库报错问题
    Winform程序调用WebService连接数据库心得
    浅谈RichTextBox在Windows Phone开发中的应用 [WP开发]
    WP7 独立存储
    安装 Visual Studio Async CTP
    C#中的弱引用(WeakReference)
    WP7开发积累
    2011.11.15
    c# 计算时间间隔
  • 原文地址:https://www.cnblogs.com/memset/p/Duilib_Error_Compiling_On_VS2012.html
Copyright © 2020-2023  润新知