Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

Im trying to call a Windows API, but the compiler gives an undeclared identifier error (C2065). Why?

0
Posted

Im trying to call a Windows API, but the compiler gives an undeclared identifier error (C2065). Why?

0

The most likely reason is that the header files you are using to build are out-of-date and do not include the features you’re trying to use. The headers that came with Visual C++ 6 are extremely old, and if you are still using them, you will run into this problem often. You can get updated header files by downloading the Platform SDK from Microsoft. Microsoft recently created an online installer, much like Windows Update, called SDK Update. If you do not want to use this page (it requires you to install an ActiveX control), you can download the SDK CAB files and install the SDK from that local copy. You can also order the SDK on CD from the SDK Update site. If you have downloaded the latest header files and are still getting compiler errors, read on. The Windows header files can be used to build programs for any version of Windows starting with Windows 95 and NT 3.51. Since not all APIs are present in all versions of Windows, there is a system that prevents you from using APIs that are

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.