Re: [python-win32] gencache module and read-only access to python dir

2007-06-19 Thread Ross McKerchar
Grzegorz Adam Hankiewicz wrote: > Ross McKerchar wrote: > >> b) Let me know if there's a more robust way of preventing the cache >> write (there appears to be code supporting freezing functionality that >> should help but I couldn't figure out a neat way of

[python-win32] gencache module and read-only access to python dir

2007-06-18 Thread Ross McKerchar
I've noticed that the GetModuleForTypelib always (or at least once per program-run) calls AddModuleToCache (both in win32com.client.gencache). This results in an attempt to write to the pickled dictionary gen_py/dicts.dat. Unfortunately the program I'm writing that uses GetModuleForLib is run b

Re: [python-win32] extending com objects

2007-05-25 Thread Ross McKerchar
Tim Golden wrote: > This -- just in case you haven't come across the expression -- > is called monkey-patching. It's a slightly general-purpose > example of it, but it's something which is usefully easy > to do in Python. (Consequently, it's easy to abuse but...) Ah right - nice to know my dodgy h

Re: [python-win32] extending com objects

2007-05-24 Thread Ross McKerchar
A few months ago I posted asking for some advice on ways to extend classes provided by com objects. Primarily I was keen to make a com library that I work with a lot (Notes/Domino if anyone's interested) nicer and more pythonic to use. I've spent a good few hours bashing away and have found two

Re: [python-win32] odd problem with Microsoft Word

2007-03-18 Thread Ross McKerchar
Kelie wrote: > The simple code shown below runs fine. It adds a custom document property to > the > active word document. But as soon as i use makepy on the "Microsoft Office > 11.0 > Object Library (2.3)", i get an AttributeError when run the same code: > AttributeError: ' Library.DocumentProper

Re: [python-win32] Reusing a local com server object

2007-03-07 Thread Ross McKerchar
Roger Upole wrote: > Ross McKerchar wrote: > >> Any suggestions would be much appreciated - even just some key phrases >> that may help energise my search efforts... >> > An object needs to be registered in the Running Object Table (R

[python-win32] Reusing a local com server object

2007-03-06 Thread Ross McKerchar
I am having trouble connecting to an already running python com server. I have set CLSCTX_LOCAL_SERVER for my com object and I am using the "GetObject" function in my vbscripts which connect to the com server. I have written a simple test server that behaves very similarly to my real server (ex

Re: [python-win32] extending com objects

2006-12-21 Thread Ross McKerchar
Tim Golden wrote: > As you will realise if you've looked at my code, I'm > using a delegation model. (Sounds grand, doesn't it: > a delegation model!) Which basically means I keep > a copy of the WMI COM object inside my own class and > proxy things across where needed. > > Can't see why you could

[python-win32] extending com objects

2006-12-18 Thread Ross McKerchar
Could somebody please confirm that my objectives below are neither 1) Reinventing the wheel or 2) Attempting something that has deliberately _not_ been done by someone far wiser than me. Put simply I want to extend a com object, which, if I understand correctly is not possible in the "normal" [

Re: [python-win32] Unpackaged binary version of pywin32

2006-11-22 Thread Ross McKerchar
David Fraser wrote: > Ross McKerchar wrote: >> If there's enough interest I'll post it for download. > I guess me asking would count as enough interest then? I'd be interested > in the setup script used for it as well... Sorry for the delay. It's all ava

Re: [python-win32] Unpackaged binary version of pywin32

2006-11-17 Thread Ross McKerchar
Paul Moore wrote: > On 11/14/06, Ross McKerchar <[EMAIL PROTECTED]> wrote: >> I would like to repackage the win32 extensions as an msi using the the >> bdist_msi distutils extension, allowing me to deploy the package to >> multiple clients using group policy. &g

[python-win32] Unpackaged binary version of pywin32

2006-11-14 Thread Ross McKerchar
Is there anywhere I can download a compiled but unpackaged version of pywin32? I would like to repackage the win32 extensions as an msi using the the bdist_msi distutils extension, allowing me to deploy the package to multiple clients using group policy. The sourceforge project page only lists