几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量

几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量 (http://www.dimcax.com/hust/index.php)
-   ObjectARX(C++) (http://www.dimcax.com/hust/forumdisplay.php?f=34)
-   -   【转帖】(求助)arxheaders.h 头文件使用 (http://www.dimcax.com/hust/showthread.php?t=8366)

yang686526 2009-04-19 03:37 PM

【转帖】(求助)arxheaders.h 头文件使用
 
(求助)arxheaders.h 头文件使用
(求助)arxheaders.h 头文件使用
初学arx 碰到了点问题
描述如下:
依照arxsdk 08 里的教程例子 setp01(objectarx 8\arxlabs\objectarxlabs.chm)
我们可以得到一个使用win32项目下的一个arx控件,在该控件里,引用了诸如“ace.h”等标准的cad sdk 头文件。
为了代码的优化,我把arxheaders.h 加入到stdafx.h中 ,以使的开发过程中不必依次重复书写各个头文件,但是编译时却遇到如下错误:
主要是说一些变量未定义。variant
很奇怪。
c:\objectarx 8\inc\acvalue.h(91) : error c4430: missing type specifier - int assumed. note: c++ does not support default-int
1>c:\objectarx 8\inc\acvalue.h(91) : error c2143: syntax error : missing ',' before '&'
1>c:\objectarx 8\inc\acvalue.h(111) : error c2059: syntax error : '<cv-qualifer>'
1>c:\objectarx 8\inc\acvalue.h(111) : error c2238: unexpected token(s) preceding ';'
1>c:\objectarx 8\inc\acvalue.h(146) : error c4430: missing type specifier - int assumed. note: c++ does not support default-int
1>c:\objectarx 8\inc\acvalue.h(146) : error c2143: syntax error : missing ',' before '&'
1>c:\objectarx 8\inc\acvalue.h(169) : error c2061: syntax error : identifier 'variant'
1>c:\objectarx 8\inc\acvalue.h(192) : error c4430: missing type specifier - int assumed. note: c++ does not support default-int
1>c:\objectarx 8\inc\acvalue.h(192) : error c2143: syntax error : missing ',' before '&'
1>c:\objectarx 8\inc\acfield.h(185) : error c2059: syntax error : '<cv-qualifer>'
1>c:\objectarx 8\inc\acfield.h(185) : error c2238: unexpected token(s) preceding ';'
1>c:\objectarx 8\inc\acprofile.h(100) : error c2061: syntax error : identifier 'iunknown'
1>c:\objectarx 8\inc\acprofile.h(102) : error c2061: syntax error : identifier 'iunknown'
1>c:\objectarx 8\inc\acprofile.h(104) : error c2061: syntax error : identifier 'iunknown'
1>c:\objectarx 8\inc\acpublishuireactors.h(154) : error c2061: syntax error : identifier 'iunknown'
1>c:\objectarx 8\inc\acpublishuireactors.h(175) : error c2065: 'iunknown' : undeclared identifier
1>c:\objectarx 8\inc\acpublishuireactors.h(175) : error c2065: 'punk' : undeclared identifier
1>c:\objectarx 8\inc\acpublishuireactors.h(176) : error c2065: 'pinfo' : undeclared identifier
1>c:\objectarx 8\inc\acpublishuireactors.h(176) : error c2275: 'acpublishuireactorinfo' : illegal use of this type as an expression
1> c:\objectarx 8\inc\acpublishuireactors.h(45) : see declaration of 'acpublishuireactorinfo'
1>c:\objectarx 8\inc\acpublishuireactors.h(177) : error c2448: 'acpublishuireactor::oninitpublishoptionsdialog' : function-style initializer appears to be a function definition
我参照了使用wizard 工程生成的自动代码,它在 头文件stdafx如此使用却是编译通过的, 费解。
由于初学没经验希望大大们出手指点迷津;
环境: vs 5。net; sdk objectarx 8
enviroment 里面include 和lib 也以添加。
[ 本帖最后由 tthq 于 8-8-3 08:24 pm 编辑 ]


所有的时间均为北京时间。 现在的时间是 10:27 AM.