I can't create a C++ project

Hey, I’m trying to create a C++ project but I keep getting error messages. I installed C++, C++ for games, and .NET for visual studios 2017 and nothing is working, what is the problem?

The project could not be compiled. Would you like to open it in Visual Studio?
Running C:/Program Files/Epic Games/UE_4.19/Engine/Binaries/DotNET/UnrealBuildTool.exe Teenagers Development Win64 -project=“C:/Users/Dimondman_Modder/Documents/Unreal Projects/Teenagers/Teenagers.uproject” -editorrecompile -progress -NoHotReloadFromIDE
Performing full C++ include scan (building a new target)
Creating makefile for Teenagers (no existing makefile)
@progress push 5%
Parsing headers for TeenagersEditor
Running UnrealHeaderTool “C:\Users\Dimondman_Modder\Documents\Unreal Projects\Teenagers\Teenagers.uproject” “C:\Users\Dimondman_Modder\Documents\Unreal Projects\Teenagers\Intermediate\Build\Win64\TeenagersEditor\Development\TeenagersEditor.uhtmanifest” -LogCmds=“loginit warning, logexit warning, logdatabase error” -Unattended -WarningsAsErrors -installed
Reflection code generated for TeenagersEditor in 25.0735262 seconds
@progress pop
Performing 11 actions (2 in parallel)
[2/11] Resource ModuleVersionResource.rc.inl
SharedPCH.Engine.cpp
[3/11] Resource PCLaunch.rc
Teenagers.cpp
TeenagersCharacter.cpp
TeenagersGameMode.cpp
Teenagers.init.gen.cpp
TeenagersCharacter.gen.cpp
TeenagersGameMode.gen.cpp
[10/11] Link UE4Editor-Teenagers.dll
[11/11] Link UE4Editor-Teenagers.lib
Creating library C:\Users\Dimondman_Modder\Documents\Unreal Projects\Teenagers\Intermediate\Build\Win64\UE4Editor\Development\UE4Editor-Teenagers.lib and object C:\Users\Dimondman_Modder\Documents\Unreal Projects\Teenagers\Intermediate\Build\Win64\UE4Editor\Development\UE4Editor-Teenagers.exp
LINK : fatal error LNK1181: cannot open input file ‘ws2_32.lib’
ERROR: UBT ERROR: Failed to produce item: C:\Users\Dimondman_Modder\Documents\Unreal Projects\Teenagers\Binaries\Win64\UE4Editor-Teenagers.dll
Total build time: 521.22 seconds (Local executor: 0.00 seconds)

The linker is choking on ws2_32.lib which is part of the windows sdk. That should have been set up properly by the installer. In that past, when people have had this issue, it sometimes is caused by conflicts between different installations of visual studio. Do you, or have you had, older versions of visual studio installed? You might want to ensure that all versions, including the current one, are fully uninstalled and references to old SDKs removed, and then repair or reinstall 2017.

Like Brian said…if you click on C++ for games and then click on Unreal Launcher it will select the exact Windows SDK that you need, which is 8.1. For 4.20 though, that will change to Windows 10.

The project could not be compiled. Would you like to open it in Visual Studio?

Running C:/Program Files/Epic Games/UE_4.19/Engine/Binaries/DotNET/UnrealBuildTool.exe Teens Development Win64 -project=“C:/Users/Dimondman_Modder/Documents/Unreal Projects/Teens/Teens.uproject” -editorrecompile -progress -NoHotReloadFromIDE
Performing full C++ include scan (building a new target)
Creating makefile for Teens (no existing makefile)
@progress push 5%
Parsing headers for TeensEditor
Running UnrealHeaderTool “C:\Users\Dimondman_Modder\Documents\Unreal Projects\Teens\Teens.uproject” “C:\Users\Dimondman_Modder\Documents\Unreal Projects\Teens\Intermediate\Build\Win64\TeensEditor\Development\TeensEditor.uhtmanifest” -LogCmds=“loginit warning, logexit warning, logdatabase error” -Unattended -WarningsAsErrors -installed
Reflection code generated for TeensEditor in 27.846485 seconds
@progress pop
Performing 11 actions (2 in parallel)
[2/11] Resource ModuleVersionResource.rc.inl
SharedPCH.Engine.cpp
[3/11] Resource PCLaunch.rc
TeensCharacter.cpp
Teens.cpp
TeensGameMode.cpp
Teens.init.gen.cpp
TeensCharacter.gen.cpp
TeensGameMode.gen.cpp
[10/11] Link UE4Editor-Teens.dll
[11/11] Link UE4Editor-Teens.lib
LINK : fatal error LNK1181: cannot open input file ‘ws2_32.lib’
Creating library C:\Users\Dimondman_Modder\Documents\Unreal Projects\Teens\Intermediate\Build\Win64\UE4Editor\Development\UE4Editor-Teens.lib and object C:\Users\Dimondman_Modder\Documents\Unreal Projects\Teens\Intermediate\Build\Win64\UE4Editor\Development\UE4Editor-Teens.exp
ERROR: UBT ERROR: Failed to produce item: C:\Users\Dimondman_Modder\Documents\Unreal Projects\Teens\Binaries\Win64\UE4Editor-Teens.dll
Total build time: 496.03 seconds (Local executor: 0.00 seconds)

the error message I’m getting after following your instructions