Which version of Visual Studio are you using?
When you created the second program did you create a new project?
Or did you just add a new C++ (*.cpp) file to the existing project?
Are you using one Solution with one project in it, or one Solution with
two projects in it? Or two Solutions with one project in each, etc.?
How you created the Solution, Project(s), and source code files can affect
what happens when you do a Build and Run. So you need to describe exactly
what steps you took to create the second program.
If there are two Projects in one Solution you must specify in the Properties
which one will get executed.
- Wayne