关于dsound.h的问题error C2501: 'DWORD_PTR' : missing storage-class or type specifiers
2013-04-04 14:58
656 查看
--------------------Configuration: as - Win32 Debug--------------------
Compiling...
main.cpp
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(305) : error C2146: syntax error : missing ';' before identifier 'dwReserved1'
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(305) : error C2501: 'DWORD_PTR' : missing storage-class or type specifiers
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(305) : error C2501: 'dwReserved1' : missing storage-class or type specifiers
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(306) : error C2146: syntax error : missing ';' before identifier 'dwReserved2'
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(306) : error C2501: 'DWORD_PTR' : missing storage-class or type specifiers
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(306) : error C2501: 'dwReserved2' : missing storage-class or type specifiers
执行 cl.exe 时出错.
解决办法:
Compiling...
main.cpp
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(305) : error C2146: syntax error : missing ';' before identifier 'dwReserved1'
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(305) : error C2501: 'DWORD_PTR' : missing storage-class or type specifiers
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(305) : error C2501: 'dwReserved1' : missing storage-class or type specifiers
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(306) : error C2146: syntax error : missing ';' before identifier 'dwReserved2'
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(306) : error C2501: 'DWORD_PTR' : missing storage-class or type specifiers
e:\program files\microsoft directx 9.0 sdk (october 2004)\include\dsound.h(306) : error C2501: 'dwReserved2' : missing storage-class or type specifiers
执行 cl.exe 时出错.
解决办法:
将DWORD_PTR 改为 int* 加入: #pragma comment(lib,"gxguid.lib") 就OK了
相关文章推荐
- error C2501: 'GetDocument' : missing storage-class or type specifiers 问题的处理
- unexpected 'class***或error C2501: missing storage-class or type specifiers 错误解决办法
- '_ConnectionPtr' : missing storage-class or type specifiers
- error C2501: '_Application' : missing storage-class or type specifiers
- error C2501: 'string' : missing storage-class or type specifiers
- error C2501: 'AUX_RGBImageRec' : missing storage-class or type specifiers
- 'IplImage' : missing storage-class or type specifiers
- 'HDEVNOTIFY' : missing storage-class or type specifiers
- Vc error C2629: unexpected 'class***或error C2501: missing storage-class or type specifiers
- 关于MATLAB函数不可用问题。??? Undefined function or method 'minfo' for input arguments of type 'double'.
- '_ConnectionPtr' : missing storage-class or type specifiers
- 简单的问题,用类创建一个对象error C2380: type(s) preceding 'Complex' (constructor with return type, or illegal redefinition of current class-n
- error: expected constructor, destructor, or type conversion before '(' token问题
- missing storage-class or type specifiers的原因及解决办法
- missing storage-class or type specifiers的解决方法
- 关于ImageIO: CGImageRead_mapData 'open' failed ' XXX error = 2 (No such file or directory)问题
- 做MFC的时候引用了头文件但VC还是报missing storage-class or type specifiers
- 解决 C++错误 error C2679: binary '=' : no operator defined which takes a right-hand operand of type 'class CString' (or there is no
- The type or namespace name 'Windows' does not exist in the class or namespace 'System'
- cocoa Unknown type name 'class'; did you mean 'Class'? 问题的解决