Showing posts with label python .net c#. Show all posts
Showing posts with label python .net c#. Show all posts

Tuesday, May 4, 2010

python and .net – unlikely symbiosis

 

If you love python and want to use all the libraries of python but you also need to work on .NET projects. You might be tempted to look at IronPython…but unless MS openly supports IronPython in VS and also all those libraries that makes Python such a kick ass language, you should skip it.

On the other hand, I found “pythonnet”, this is probably one of the best answer on using python and .net . 

http://pythonnet.sourceforge.net/readme.html

All you need to do is copy the clr.pyd file to ur python installation directory and also the python.runtime.dll file and you can do things  like …

import clr
import System.Windows.Forms as WinForms
from System.Drawing import Color, Size, Point
from System.Text import Encoding
from System.IO import File
import System

class Wordpad(WinForms.Form):
    """A simple example winforms application similar to wordpad."""

…

 

Cool like hell!.