Python Forum

Full Version: Import error when trying to import DDE (part of PyWin32)
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi Everyone,

I am trying to use dynamic data exchange (DDE) under Windows 7 using Python 2.7. After installing PyWin32 I have tried to run the ddeclient.py to do a first test. I got the following error:

Traceback (most recent call last):
File "C:\Python27\Lib\site-packages\win32\Demos\dde\ddeclient.py", line 4, in <module>
import dde
ImportError: This must be an MFC application - try 'import win32ui' first

ddeclient.py starts with the following code:
# 'Request' example added jjk  11/20/98

import win32ui
import dde
I have tried the same command from command line and got the same error all times. I have looked for a solution in internet and saw several people with the same problem but no solution. How can I solve this problem?

Thanks in advance for any help.