473,614 Members | 2,487 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

makepy must be run after restart of pythonwin

bk
hi,

thank you for the hint, but i solved the problem myself.
i didnt knew that that the following two lines in py-script must be added:

from win32com.client import gencache
gencache.Ensure Module('{00062F FF-0000-0000-C000-000000000046}', 0,8,0)

now it works fine. my skills in python in python are not really advanced, so
the python-mailinglists are good help for me.

so long
ben

hi,

i'm using pythonwin 2.2.3
my programm reads and write the outlook-adress book using COM. for this i
have to use the makepy utility. after i have run the utiltity everything is
fine and i can run my py-file without any errors.
but if i close the pythonwin and restart and then try to run my py-script i
get the following error:

File "C:\Program Files\Python22\ contacts_ausgab e.py", line 45, in
DumpDefaultAdd ressBook
folder =
mapi.GetDefaul tFolder(win32co m.client.consta nts.olFolderCon tacts)
File "C:\PROGRA~1\Py thon22\lib\site-packages\win32c om\client\__ini t__.py",line 168, in __getattr__
raise AttributeError, a
AttributeError : olFolderContact s


I suggest you examine the attributes of win32com.client .constants. Perhaps
there is a case sensitivity issue. makepy can cause attributes that were
previously case insensitive to become case sensitive.

I also recall somewhere a discussion about win32com.client .constants not
being populated immediately. Consider waiting a moment after dispaching.

Bob Gailer
bg*****@alum.rp i.edu
303 442 2625
Jul 18 '05 #1
0 1811

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
543
by: bk | last post by:
hi, i'm using pythonwin 2.2.3 my programm reads and write the outlook-adress book using COM. for this i have to use the makepy utility. after i have run the utiltity everything is fine and i can run my py-file without any errors. but if i close the pythonwin and restart and then try to run my py-script i get the following error: File "C:\Program Files\Python22\contacts_ausgabe.py", line 45, in
3
2682
by: Gerson Kurz | last post by:
I have problems getting "COM makepy" working in ActivePython 2.3.2. This is what happens when I start "COM makepy" from the Pythonwin Menu: PythonWin 2.3.2 (#49, Nov 6 2003, 10:18:20) on win32. Portions Copyright 1994-2001 Mark Hammond (mhammond@skippinet.com.au) - see 'Help/About PythonWin' for further copyright information. >>> Failed to execute command: from win32com.client import makepy;makepy.main() Traceback (most recent call...
2
4018
by: Svenn-Ivar Svendsen | last post by:
Hi, I use the makepy tool in pythonwin to generate wrappers for my connection point (event) interfaces in a project. It works fine. The question is; Is it possible, in a python script, to detect if wrappers for COM (event) interfaces the script uses have been created, and in case not somehow call the makepy tool manually before proceeding? How should this be done? Best regards, Svenn-Ivar
1
1416
by: markscottwright | last post by:
Has anyone sucessfully run makepy and Microsoft Word Object Library (9.0)? Mine crashes under XP Pro and Python 2.4. It only seems to be word that has the problem, though. I get a dialog that says that pythonwin.exe has crashed: AppName: pythonwin.exe AppVer: 0.0.0.0 ModName: ntdll.dll ModVer: 5.1.2600.1217 Offset: 000096f9
2
2174
by: nvhengr | last post by:
Has anyone seen this? When I run the COM Makepy utility and choose Microsoft Excel 9.0 Object Library (1.3), I get an application error message: PythonWin: Pythonwin.exe - Application Error The instruction at "0x77fcc87" referenced memory at "0x0307a705". The memory could not be "read". I do not get this error when I choose the Microsoft Office 9.0 Object Library (2.1).
0
2224
by: Paul Keating | last post by:
I used MakePy to generate .py support for a COM dll. That created the file 30D58DAF-B538-45F1-8EFF-F69ABA2BA798x0x1x13.py I want to be sure that this file is present and so I used MakePy -i to construct a call to gencache.EnsureModule(). This is what it said:
1
3240
by: Martin Stettner | last post by:
Hi, when trying to generate the wrapper classes for Microsofts ADO Library (Version 2.8) with makepy, I run into the following problem. Here's what I do (I use ActiveState Python 2.4.1.245) 1.) Running makepy, selecting "Microsoft ActiveX Data Object 2.8" 2.) Starting PythonWin IDE
1
2719
by: Steve M | last post by:
When I use the COM Makepy utility on one computer with WindowsXP, ActivePython 2.3 and I select the library Microsoft Word 10.0 Object Library (8.2), things work fine. When I have WindowsXP, ActivePython 2.4 (build 247) and Microsoft Word 11.0 Object Library (8.3), then I get the following SyntaxError, and on two different computers I tested this. More on the error below, but has anyone else had this problem? Will there soon be a newer...
1
1326
by: bg_ie | last post by:
Hi, I have a problem where an earlier version of my Com object is being used by makepy for early binding. In makepy I see - MyCom (1.0) MyCom (1.0) MyCom (2.0) I created version 2 of my Com object hoping that this would solve the
1
1485
by: gundlach | last post by:
Hi! I've just written a Python speech-recognition module (http:// pyspeech.googlecode.com). It provides a clean and simple interface to the Microsoft Speech SDK using COM wrapper classes generated by PythonWin's MakePY utility. Once this is a mature module, I'd like to make it as useful as possible to the community, so I'd like to make installation as simple as possible. Currently, to get speech.py to work, you must first:
0
8198
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8591
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8294
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7115
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6093
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4138
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2575
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1758
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1438
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.