error C2065: 'CoSetProxyBlanket' : undeclared identifier 问题解决方法
2008-01-21 17:19
423 查看
CodeGuru Forums > Visual C++ & C++ Programming > Visual C++ Programming > Question about WMI PDA Click to See Complete Forum and Search --> : Question about WMI godspeed April 5th, 2006, 11:53 AM Hi, Can WMI be used in Visual C++ 6.0? Thanks in advance kirants April 5th, 2006, 12:05 PM Sure. godspeed April 6th, 2006, 09:40 PM I tried adding the WMI code that works in .NET but I'm getting errors saying that: error C2065: 'CoInitializeEx' : undeclared identifier error C2065: 'CoSetProxyBlanket' : undeclared identifier error C2065: 'EOAC_NONE' : undeclared identifier This same code works in .NET, it seems that the problem is a direct issue of #include <comdef.h> file being different in 6.0 and in .NET. Does anyone know how to resolve this problem. Any help would be appreciated kirants April 12th, 2006, 08:53 PM You need to #define this in your header file to use CoInitializeEx: #define _WIN32_DCOM codeguru.com Copyright 2007 Jupitermedia Corporation All Rights Reserved. |
相关文章推荐
- error C2065: 'pcap_next_ex' : undeclared identifier问题解决方法
- 解决VC++6.0 error C2065: 'ODS_HOTLIGHT' : undeclared identifier问题
- vector 解决方法 error C2065: 'vector' : undeclared identifier
- error C2065: CoInitializeEx' : undeclared identifier 解决方法
- 解决使用CPicture类出现“error C2065: 'CArchiveStream' : undeclared identifier”的问题
- 解决使用CPicture类出现“error C2065: 'CArchiveStream' : undeclared identifier”的问题
- 问题 error C2065: '_beginthreadex' : undeclared identifier 的解决办法
- error C2065: CoInitializeEx' : undeclared identifier 解决方法
- 对于 error C2065: 'GL_COMBINE_ARB' : undeclared identifier 问题的解决
- error C2065: CoInitializeEx' : undeclared identifier 解决方法
- error C2065: 'CoInitializeEx' : undeclared identifier; 解决方法
- 编译过程中弹出new(35) : error C2061: syntax error : identifier 'THIS_FILE'问题的原因及解决方法
- Visual C++ 程序设计(王明福、高教版)4.2章节___开发MyCalculator程序中的error C2065: 'UpdateDisplay' : undeclared identifier问题
- error C2065: 'AfxCriticalTerm' : undeclared identifier 解决办法
- c++ 学习中遇到的问题: error C2065: 'ifstream' : undeclared identifier
- error C2065: 'CString' : undeclared identifier错误的处理方法
- error C2065: 'AfxCriticalTerm' : undeclared identifier 解决办法
- VC++中出现错误“ error c2065 'printf' undeclared identifier”的处理方法
- VC++6.0原始套接字出现 C2065:'SIO_RCVALL' : undeclared identifier错误的解决方法
- 关于undefined reference to `inflate'问题解决方法