在一个头文件里面定义了些枚举常量, 用MIDL编译后,得到一个.h头文件, 将该文件include 到COM组件的idl文件后,
#pragma once
import "oaidl.idl";
import "ocidl.idl";
#include "myTypes.h"编译出现下面问题:
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(364) : error MIDL2003 : redefinition : _LARGE_INTEGER
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(383) : error MIDL2003 : redefinition : _ULARGE_INTEGER
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(529) : error MIDL2003 : redefinition : Int64ShllMod32
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(529) : error MIDL2025 : syntax error : expecting ; near "{"
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(531) : error MIDL2026 : cannot recover from earlier syntax errors; aborting compilation
Error executing midl.exe.将上面语句改成:
#pragma once
//import "oaidl.idl";
//import "ocidl.idl";
#include "myTypes.h"
又出现错误:
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(529) : error MIDL2003 : redefinition : Int64ShllMod32
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(529) : error MIDL2025 : syntax error : expecting ; near "{"
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(531) : error MIDL2026 : cannot recover from earlier syntax errors; aborting compilation
Error executing midl.exe.可能问题在什么地方? 多谢。
#pragma once
import "oaidl.idl";
import "ocidl.idl";
#include "myTypes.h"编译出现下面问题:
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(364) : error MIDL2003 : redefinition : _LARGE_INTEGER
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(383) : error MIDL2003 : redefinition : _ULARGE_INTEGER
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(529) : error MIDL2003 : redefinition : Int64ShllMod32
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(529) : error MIDL2025 : syntax error : expecting ; near "{"
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(531) : error MIDL2026 : cannot recover from earlier syntax errors; aborting compilation
Error executing midl.exe.将上面语句改成:
#pragma once
//import "oaidl.idl";
//import "ocidl.idl";
#include "myTypes.h"
又出现错误:
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(529) : error MIDL2003 : redefinition : Int64ShllMod32
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(529) : error MIDL2025 : syntax error : expecting ; near "{"
d:\Microsoft Visual Studio\VC98\INCLUDE\winnt.h(531) : error MIDL2026 : cannot recover from earlier syntax errors; aborting compilation
Error executing midl.exe.可能问题在什么地方? 多谢。
解决方案 »
- 如何获得光标处的表格对象?
- Escomm::CComTcp是什么定义的
- 用VC怎样将一个二进制数据(结构或buffer)存到Sql Server中?????
- 急!可能是很简单的问题,可是我弄不明白!请各位帮忙!
- 如何聪动态链接库中输出类?
- 很多软件上面,有一个开机时是否启动该软件的复选框,这个是怎么实现的?
- 我在win32参考大全里没有找到TCN_SELCHANGE消息,哪位能告诉我。。。
- 把头文件添加到工程中,和使用"#include"包含进来,有什么区别???
- 谁有压缩目录下的文件的原代码?
- ***Netbit Browser-中国人自己的开放源码浏览器*****
- MFC如何通过ole读取现有excel文件中的内容?
- 注入系统进程问题
头文件...用MIDL编译...????