Re: Can I embed Windows Python in C# or VC++?
- From: Christian Heimes <lists@xxxxxxxxxx>
- Date: Fri, 07 Dec 2007 12:07:07 +0100
sturlamolden wrote:
The answer is YES. C# can access C functions exported by any DLL with
platform invoke. Since the Python C API is plain C and not C++ you can
gain access to it from C#. Import System.Runtime.InteropServices and
write wrappers like
[DllImport("Python25.dll"), CallingConvention=CallingConvention.Cdecl]
public static void Py_Initialize();
There is no need for that. PythonDotNET wraps the P/Invokes and internal
C API of CPython in a nice .NET API.
Christian
.
- References:
- Can I embed Windows Python in C# or VC++?
- From: grbgooglefan
- Re: Can I embed Windows Python in C# or VC++?
- From: Gabriel Genellina
- Re: Can I embed Windows Python in C# or VC++?
- From: grbgooglefan
- Re: Can I embed Windows Python in C# or VC++?
- From: Gabriel Genellina
- Re: Can I embed Windows Python in C# or VC++?
- From: sturlamolden
- Can I embed Windows Python in C# or VC++?
- Prev by Date: Re: Erros when compiling a CPP program which uses CPython API functions
- Next by Date: File to dict
- Previous by thread: Re: Can I embed Windows Python in C# or VC++?
- Next by thread: Re: Can I embed Windows Python in C# or VC++?
- Index(es):
Relevant Pages
|