[prev in list] [next in list] [prev in thread] [next in thread] 

List:       python-list
Subject:    Re: importing win32com.client.Dispatch with embedded interpreter
From:       Gordon McMillan <gmcm () hypernet ! com>
Date:       2001-07-31 22:51:21
[Download RAW message or body]

[posted and mailed]

Mike Haspert wrote:

> The minimal function f1(), below in usecom.py, runs fine from the
> command line, but when I use the C API for the interpreter, it runs
> the first time and fails thereafter. Can anyone see what I'm doing
> wrong? The error message "TypeError: this constructor takes no
> arguments" has me stumped.

[snip]

> int minimal(char* modname)
> {
>     bool success = false;
>     PyObject *mod,*func,*args,*rvals;
>     Py_Initialize();

[snip]

It's got nothing to do with f1.

You can't Py_Initialize() twice.

- Gordon
-- 
http://mail.python.org/mailman/listinfo/python-list

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic