Hi friends;
I would like to pass a string into a dll function. I notice that to pass using
ctypes, it has to be a ctypes type. Looking at the ctypes doc page I don't see
a c_string class.
I tried to pass in byref("name of string") and got back "TypeError: byref()
argument must be a ctypes instance, not 'str'"
If I use astr = create_string_buffer( "name of string" ), and try to pass that
in, I get "ValueError: Procedure probably called with too many arguments (4
bytes in excess)".
If I use astr = (c_char*255)("name of string"), I get "TypeError: one character
string expected" (on this line).
Could some benevolet expert please clue me in on how to accomplish this?
Thanks!!!!
Mark
--
http://mail.python.org/mailman/listinfo/python-list