Visual Studio opens when running the program in the terminal

Hello. I have a little trouble after running the triplex in the terminal

It asked me with what program I want to open the executed file, and I accidentially clicked on Visual Studio (not VS Code), now everytime I run it in the terminal Visual Studio opens.
How can change that back? thank you

1 Like

You runnign windows? if so i’d go to the start menu and search for “default apps” then click on “choose default apps by file type”, then hunt around for the offendingn file type in the list.

You are likely typing “triplex.cpp” in the terminal which is just going to open the file in the default application for that file type, it’s no different to double clicking it in File Explorer.

cl triplex.cpp

This compiles the file triplex.cpp and outputs an executable of the same name i.e. “triplex.exe”. If you type that then it will run that program

triplex.exe

The .exe is optional and you can run it simply by typing

triplex

Note the lack of file extension.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms