CallBack function in C Libraries.
Mark H Harris
harrismh777 at gmail.com
Fri Mar 21 12:50:18 EDT 2014
On 3/21/14 7:02 AM, fiensproto at gmail.com wrote:
> Yep, Many thanks for help....
> Hum, i have find the solution, it was in "CallBack function" in help-doc.
No, it was not in the "CallBack function" in help-doc ...
>
> def TheProc(): <================== you moved c_int from here ...
> fpgui.fpgFormWindowTitle(0, 'Boum')
> return 0
>
{snip}
>
> CMPFUNC = CFUNCTYPE(c_int) <============ and placed it here ...
>
> TheProcF = CMPFUNC(TheProc) <========== so that when you called TheProc ...
... it wasn't "expecting" exactly one parameter. So, your python
traceback no longer warns about the parameter 'mismatch' in the defined
function TheProc().
I'm not picking on you, but this error was obvious; as was it's
solution, so I'm just wondering ?
Cheers
More information about the Python-list
mailing list