Python Forum
Import error when trying to import DDE (part of PyWin32)
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Import error when trying to import DDE (part of PyWin32)
#1
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.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Puzzling import issue that I have no idea how to solvr starseeker 3 520 Feb-21-2024, 05:07 PM
Last Post: deanhystad
  Different Ways to Import Modules RockBlok 2 538 Dec-11-2023, 04:29 PM
Last Post: deanhystad
  How secure is the use of "secret" import? ejwjohn 12 1,259 Nov-09-2023, 08:31 AM
Last Post: ejwjohn
  is import cointegration_analysis a recognized module mitcht33 1 432 Nov-06-2023, 09:29 PM
Last Post: deanhystad
  error "cannot identify image file" part way through running hatflyer 0 679 Nov-02-2023, 11:45 PM
Last Post: hatflyer
  problem in import module from other folder akbarza 5 1,435 Sep-01-2023, 07:48 AM
Last Post: Gribouillis
  can not import anaconda pandas module. PySpark pandas module is imported!! aupres 0 723 Aug-06-2023, 01:09 AM
Last Post: aupres
  Error on import: SyntaxError: source code string cannot contain null bytes kirkwilliams2049 7 6,820 Aug-03-2023, 06:00 PM
Last Post: Gribouillis
  I try to import Vpython and I get a "ZeroDivisionError" Jon2222 16 2,634 Jul-26-2023, 07:37 AM
Last Post: Jon2222
  [WORKED AROUND] Problem installing elitech-datareader, 'cannot import build_py_2to3' NeilUK 4 1,718 Jul-09-2023, 10:01 AM
Last Post: NeilUK

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020