您的位置:首页 > 其它

error MIDL2025 : syntax error : expecting a type specification near "HRESULT"解决办法

2011-11-24 18:13 495 查看
在vc6.0用ATL建立一个COM组件,然后在接口定义中加入方法,会遇到编译错误:

(1)error MIDL2025 : syntax error : expecting a type specification near "HRESULT"

(2)error MIDL2026 : cannot recover from earlier syntax errors; aborting compilation

解决办法:

(1)在加入的新接口的.odl文件头加上import "ocidl.idl",

(2)重新编译,错误消失.
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐