Can I embed Windows Python in C# or VC++?

grbgooglefan ganeshborse at gmail.com
Thu Dec 6 23:24:57 EST 2007


On Dec 7, 12:17 pm, "Gabriel Genellina" <gagsl-... at yahoo.com.ar>
wrote:
> En Thu, 06 Dec 2007 23:27:15 -0300, grbgooglefan <ganeshbo... at gmail.com>  
> escribió:
>
> > I want to use Python's Windows (python25.dll) version to embed in my
> > C# (or atleast VC++) program for performing syntax checks on the
> > Python expressions which are later supposed to be evaluated at runtime
> > by another C++ program
>
> > For this, I would like to use CPython API functions such as
> > Py_Initialize, PyModule_New, PyModule_GetDict, PyRun_String,
> > PyObject_GetAttrString, PyObject_CallObject, PyTuple_SetItem & other
> > similar functions from my C#/ VC++ program on Windows.
>
> > I have installed Python251.msi on my Desktop.
> > Can I start doing the development using the include, lib & the
> > python25.dll files availale after installing this MSI?
>
> Yes. You don't require the source package to embed Python and use the API  
> in your programs.
>
> --
> Gabriel Genellina

Does it mean, I can embed Python in C# as well with the same APIs?



More information about the Python-list mailing list