Running Python script from C++ code(.NET)
Mc Osten
riko at despammed.com
Sun Sep 24 14:16:31 EDT 2006
volcano <Mark.Geyzer at gmail.com> wrote:
> A trivial question - I have a working Python script that I have to
> invoke from C++ code. No fancy stuff - just run the whole script with
> its parameters. No callbacks, no signalling - nada, just
> stupid,primitive, straightforward call.
In a unix based environment I would use fork + exec*. IIRC in Windows
you should have a CreateProcess function call.
<http://goffconcepts.com/techarticles/development/cpp/createprocess.html
>
<http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dllpro
c/base/createprocess.asp>
You could also try system, but it's generally considered insecure.
--
blog: http://www.akropolix.net/rik0/blogs | Uccidete i filosofi,
site: http://www.akropolix.net/rik0/ | tenetevi riso e
forum: http://www.akropolix.net/forum/ | bacchette per voi.
More information about the Python-list
mailing list