Python_Learner
Python_Learner

Reputation: 1637

Anaconda prompt launches Visual Studio 2017 when run .py Files

Traditionally I've used Notepad ++ along with the Anaconda prompt to write and run scripts locally on my Windows PC.

I had my PC upgraded and thought I'd give Virtual Studio Code a chance to see if I liked it.

Now, every time I try to execute a .py file in the Anaconda prompt Visual Studio 2017 launches. I hate this and can't figure out how to stop it.

I've tried the following:

  1. Uninstalling Virtual Studio Code.
  2. Changing environments in Anaconda.
  3. Reinstalling Anaconda. I did not check the box for the %PATH option.
  4. Reboots at every step.

On my Windows 10 laptop Visual Studio 2017 doesn't appear in my Apps and Features to uninstall. I've tried Googling and am stuck.

The programs involved are:

Windows 10 Professional

Visual Studio 2017

Anaconda version 2019.10 Build Channel py37_0

Can someone help me figure out how to stop this?

Upvotes: 0

Views: 85

Answers (1)

K.Cl
K.Cl

Reputation: 1763

How were you running the scripts before? python script.py or only script.py?

If it is the latter, what happened probably is that Windows has associated .py files to Visual Studio. Right click on the file, go to Open With, then select Python if you want to run them, or Notepad++ if you want to edit them.

Upvotes: 1

Related Questions