环境为xp+2003 FEB SDK+VC6.0 .
也装过xp full sdk,2004.8,有装了vs.net2003一直有编译错误如下:
c:\program files\microsoft sdk\include\mshtml.h(5204) : error C2059: syntax error : 'constant'
c:\program files\microsoft sdk\include\mshtml.h(5207) : error C2143: syntax error : missing ';' before '}'
c:\program files\microsoft sdk\include\mshtml.h(5207) : error C2501: 'BoolValue' : missing storage-class or type specifiers
c:\program files\microsoft sdk\include\mshtml.h(63025) : error C2143: syntax error : missing ';' before '}'
c:\program files\microsoft sdk\include\mshtml.h(63025) : error C2143: syntax error : missing ';' before '}'
c:\program files\microsoft sdk\include\mshtml.h(63025) : error C2143: syntax error : missing ';' before '}'
d:\my documents\code\sp1_module_osip\sp1_module_osip\domainconf.h(6) : error C2143: syntax error : missing ';' before '{'
d:\my documents\code\sp1_module_osip\sp1_module_osip\domainconf.h(6) : error C2447: missing function header (old-style formal list?)搞了好久了,大家帮忙啊
也装过xp full sdk,2004.8,有装了vs.net2003一直有编译错误如下:
c:\program files\microsoft sdk\include\mshtml.h(5204) : error C2059: syntax error : 'constant'
c:\program files\microsoft sdk\include\mshtml.h(5207) : error C2143: syntax error : missing ';' before '}'
c:\program files\microsoft sdk\include\mshtml.h(5207) : error C2501: 'BoolValue' : missing storage-class or type specifiers
c:\program files\microsoft sdk\include\mshtml.h(63025) : error C2143: syntax error : missing ';' before '}'
c:\program files\microsoft sdk\include\mshtml.h(63025) : error C2143: syntax error : missing ';' before '}'
c:\program files\microsoft sdk\include\mshtml.h(63025) : error C2143: syntax error : missing ';' before '}'
d:\my documents\code\sp1_module_osip\sp1_module_osip\domainconf.h(6) : error C2143: syntax error : missing ';' before '{'
d:\my documents\code\sp1_module_osip\sp1_module_osip\domainconf.h(6) : error C2447: missing function header (old-style formal list?)搞了好久了,大家帮忙啊
下面是5204行附近的代码:
EXTERN_C const GUID CLSID_CFramesCollection;
EXTERN_C const GUID CLSID_CScreen;
EXTERN_C const GUID CLSID_CWindow;
EXTERN_C const GUID CLSID_COmWindowProxy;
typedef
enum _htmlCompatMode
{ htmlCompatModeBackCompat = 0,
htmlCompatModeCSS1Compat = 1,
htmlCompatMode_Max = 2147483647L
} htmlCompatMode;EXTERN_C const GUID CLSID_CDocument;
EXTERN_C const GUID CLSID_CScriptlet;
typedef
enum _BoolValue
{ True = 1,
False = 0,
BoolValue_Max = 2147483647L
} BoolValue;EXTERN_C const GUID CLSID_CPluginSite;
EXTERN_C const GUID CLSID_CAreasCollection;
EXTERN_C const GUID CLSID_CMapElement;
EXTERN_C const GUID CLSID_CAreaElement;
typedef
enum _htmlCaptionAlign
{ htmlCaptionAlignNotSet = 0,
htmlCaptionAlignLeft = 1,
htmlCaptionAlignCenter = 2,
htmlCaptionAlignRight = 3,
htmlCaptionAlignJustify = 4,
htmlCaptionAlignTop = 5,
htmlCaptionAlignBottom = 6,
htmlCaptionAlign_Max = 2147483647L
} htmlCaptionAlign;
不是我加的,是没有constant的,只是个enum数据
我同事那就可以打开,他也是2003+2003 sdk+vc6.0
directories里include和lib的顺序也和我一样,我就不可以打开
快疯掉了
//////////////////////////////
这句报错不是因为constant吗?
c:\program files\microsoft sdk\include\mshtml.h(5204) : error C2059: syntax error : 'constant'
看看有没有constant
那么多错误都是vc莫名其妙的错误
vc有的时候有这种错误
好像一般头文件包含什么的出问题就那样
我装sdk是为了用tpipv6.henum _BoolValue
{ True = 1, //5204
False = 0,
BoolValue_Max = 2147483647L
} BoolValue;
我用vc6.0自带的mshtml.h替代了sdk的那个文件