How can I create a working C++ file in which the compiler outputs a simple Hello World without getting 475 errors.

Clemens Fischer 0 Reputation points

Since many weeks I tried to programm C++ in visual studio, but the compiler always gives me 475 errors, so I thought the reson is the SDK. After changing between some different Windows SDKs it worked, but about one week later it stopped working again.

Visual Studio Debugging
Visual Studio Debugging
Visual Studio: A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.Debugging: The act or process of detecting, locating, and correcting logical or syntactical errors in a program or malfunctions in hardware. In hardware contexts, the term troubleshoot is the term more frequently used, especially if the problem is major.
912 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Anna Xiu-MSFT 23,251 Reputation points Microsoft Vendor

    Hi @Clemens Fischer

    Welcome to Microsoft Q&A! 

    Does it occur in all projects or specific project? 

    As you said, you changed the Windows SDKs before. Can you install the Windows 11 SDK (10.0.22621.0) via Visual Studio Installer?

    Then, run VS as administrator and change the Windows SDK Version in project property to the latest version. 

    Besides, the crtdbg.h should be located at C:\Program Files (x86)\Windows Kits\10\Include\10.0.22621.0\ucrt.

    If you find the crtdbg.h on a different path, please copy the directory path where the crtdbg.h is located.

    Then, manually add the path into Include Directories and rebuild your project. 



    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment". 
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.