2

Steps to reproduce:

  1. I created a new project in Visual Studio
  2. Selected Python > Desktop > "IronPython Windows Forms Application"

However, as soon as I open the project I encountered several errors which I don't know how to solve. The errors are unresolved import clr an similar.

Brand New Windows Forms Python Project

KyleMit
  • 30,350
  • 66
  • 462
  • 664
user1746636
  • 47
  • 1
  • 1
  • 5

1 Answers1

2

If you're getting the following error unable to resolve 'clr':

Example Error

It's likely that you don't have a python interpreter installed or configured for Visual Studio

Per the question The environment ironpython 2.7-32 appears to be incorrectly configured or missing

The Visual Studio Installer does not include an IronPython Package option to install

So you need to:

  1. Download IronPython from Github and install it
  2. Then, select the correct Python environment within your VS project.
KyleMit
  • 30,350
  • 66
  • 462
  • 664
  • 1
    Hi KyleMit, sorry for haven't given you an answer sooner. Lot of work and family affairs ... I've installed the IronPython Package and also selected the 3.7 64 bit Python environment but the warnings still appear. It's very surprising this happens. I believe it might be something related to he .NET framework as they are .NET assemblies. Thank you very much for your help. – user1746636 May 30 '19 at 07:49