This guide will walk you through how to setup Visual Studio Code for C++ Programming. You will be installing the followings:
You can watch the video following this codelab on youtube. Click on this video link.
Download VS Code and run
CTRL P
to open an input box on top of the window,
and type:
ext install IDwhere
ID
is the reference ID of the extension that you want to install.Example command: to
install C/CPP extension
ext install ms-vscode.cpptools
c:\
driveEnvironment variable
Edit the system environment variables
System Properties
, click on the button Environment Variables
.
Environment Variables
, under the section System variables
,
double-click on the variable Path
.Edit environment variable
, click on the button New
to add a new
path.Type:
c:\mingw\bin
c:\mingw\vscode-cpp-samples
single-file-programs
into VS Code, (or right click the
folder and click on the menu Open with VS Code
)When working with VS Code, you always want to work in a folder. You may have:
"Console Program"
or "Graphic Program"
"Multi-file Console Project"
or "Multi-file Graphic Project"
program1
.C:\mingw\vscode-cpp-samples\single-file-program
) to the new folder program1
.
program1
into a VS Code instance.