Cpython interpretter / IronPython interpretter No module named clr
Asked Answered
V

3

5

i'm using IronPython and i want to create some windows form, i want to create a windows form with some button, and i want to do this in visual studio with iron python, i'm using visual studio 2012 integrated edition, each time i create an "ironpython windows form" project, when i want to run it, it says:

The project is currently set to use the .NET debugger for IronPython debugging but the project is configured to start with a CPython interpreter. To fix this change the debugger type in project properties->Debug->Launch mode

when i change debugger to Standard Python Launcher, it says:

ImportError: No module named clr

what should i do?

Ventriloquist answered 16/10, 2012 at 1:15 Comment(2)
Have you tried telling it to use IronPython?Gilgai
i don't know if i got your point or not, but actually i have to go to the project properties->Debug->Launch and set "launch mode" to something other than "IronPython.net Launcher" in order to get rid of the first error message, and it causes the second errorVentriloquist
A
6

I got the same error and resolved it with these steps:

I changed the project properties General>Interpreter to IronPython 2.7 Debug>Launch mode to IronPython(.NET) launcher

At first I didn't see IronPython as an interpreter option to select from. I added the path to IronPython installation to my Path System variable, restarted Visual Studio and it worked.

Advocaat answered 1/11, 2012 at 18:28 Comment(0)
C
1

I understand this is an old question, but I ran into the same thing today, and did not find any satisfactory answers.

I'm working with a new install of Visual Studio 2015 - Community under Windows 8.1. After installing a bunch of additional add-ons and tool boxes, I thought it would be complete. I had an IronPython debug option in VS, but it had not been (successfully) installed!

If you're having issues with IronPython, look in C:\Program Files (x86), and verify the directory IronPython 2.7 exists.

(IronPython 2.7 is available at http://ironpython.codeplex.com/releases/view/169382.)

Once you have verified installation was successful, setup your development environment:

  • Create a Python project in Visual Studio
  • At the bottom of the Project menu, click <project name> Properties
  • On the General page, select IronPython 2.7 as your interpreter
  • On the Debug page, set Launch mode to IronPython (.Net) launcher
  • Finally, click on Debug Standard Library.

Using that setup, I was able to generate a blank Windows form application, and start it with/without debugging.

Convulse answered 28/3, 2016 at 2:24 Comment(0)
V
0

OK dudes, i tell you how i solved the problem, i reinstalled everything from the scratch, i used to use visual studio express, but i installed the "professional" version, then i reinstalled everything from http://ironpython.codeplex.com/releases/view/81726 and suddenly all things worked fine in the console, then voila, ironpython windows form project in visual studio is working now :)

Ventriloquist answered 16/10, 2012 at 12:16 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.