2013-01-27, 18:05
Hello "Phyton" professionals, Please Help!
I have a "PhytonScript" that sends an event to "EventGhost".
On the first call, everything is ok!
On the second call comes the error:
Can someone help me?
Sensman
I have a "PhytonScript" that sends an event to "EventGhost".
PHP Code:
import os
import sys
import win32api
from win32com.client import Dispatch
eg = Dispatch("EventGhost")
eg.TriggerEvent(u"FireEvent")
On the first call, everything is ok!
On the second call comes the error:
PHP Code:
16:53:47 T:10640 NOTICE: -->Python Interpreter Initialized<--
16:53:47 T:10640 ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <type 'exceptions.AttributeError'>
Error Contents: 'NoneType' object has no attribute 'platform'
Traceback (most recent call last):
File "C:\KLOTZ Client\Main\portable_data\addons\script.fireevent\fireevent.py", line 4, in <module>
from win32com.client import Dispatch
File "C:\KLOTZ Client\Main\system\python\lib\site-packages\win32com\__init__.py", line 6, in <module>
import pythoncom
File "C:\KLOTZ Client\Main\system\python\lib\site-packages\pythoncom.py", line 3, in <module>
pywintypes.__import_pywin32_system_module__("pythoncom", globals())
File "C:\KLOTZ Client\Main\system\python\lib\site-packages\win32\lib\pywintypes.py", line 20, in __import_pywin32_system_module__
if not sys.platform.startswith("win32"):
AttributeError: 'NoneType' object has no attribute 'platform'
-->End of Python script error report<--
Can someone help me?
Sensman