[IPython-User] pythonnet and IPython
Dave Hirschfeld
dave.hirschfeld@gmail....
Tue Nov 6 10:27:28 CST 2012
John Burkhart <jfburkhart.reg <at> gmail.com> writes:
>
> Thank you both. Given the situation, may I take this 'OT' briefly and just ask
opinions...
>
>
> -john
>
I haven't tried running the pythonnet executable, but I've compiled
pythonnet with VS2010 targeting .NET4/Python27. By copying clr.pyd,
Python.Runtime.dll and Python.Runtime.dll.config to my Python
(sys.prefix) directory I can then import .NET4 dlls from a normal
IPython session.
In [54]: import clr
In [55]: import System
In [56]: d = System.DateTime.Now
In [57]: d
Out[57]: <System.DateTime at 0x7f95a80>
In [58]: print d
06/11/2012 16:24:56
In [59]: print d.AddDays(1)
07/11/2012 16:24:56
In [60]:
HTH,
Dave
More information about the IPython-User
mailing list