Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- __declspec(dllexport) int sum(int a, int b) {
- return a + b;
- }
- from ctypes import cdll
- mydll = cdll.LoadLibrary('libTest.dll')
- if __name__ == '__main__':
- pass
- Traceback (most recent call last):
- File "C:Usersrobertodg.p2poolpluginsorg.python.pydev.core_6.4.3.201807050139pysrc_pydev_runfilespydev_runfiles.py", line 468, in __get_module_from_str
- mod = __import__(modname)
- File "C:Usersrobertodgeclipse-workspaceLetsHopeHope.py", line 8, in <module>
- mydll = cdll.LoadLibrary('libTest.dll')
- File "C:UsersrobertodgAppDataLocalProgramsPythonPython37-32libctypes__init__.py", line 434, in LoadLibrary
- return self._dlltype(name)
- File "C:UsersrobertodgAppDataLocalProgramsPythonPython37-32libctypes__init__.py", line 356, in __init__
- self._handle = _dlopen(self._name, mode)
- OSError: [WinError 193] %1 is not a valid win32 application
Add Comment
Please, Sign In to add comment