I\'m having an issue with ctypes. I think my type conversion is correct and the error isn\'t making sense to me. Error on line \" arg - ct.c_char_p(logfilepath) \" TypeErro
c_char_p takes bytes object so you have to convert your string to bytes first:
c_char_p
bytes
string
ct.c_char_p(logfilepath.encode('utf-8'))
Another solution is using the c_wchar_p type which takes a string.
c_wchar_p