Re: [python-win32] How to use GetProperty and PutProperty COM interface in IE?

2007-05-30 Thread Tim Roberts
Richard Bell wrote: > I'm having trouble using the GetProperty and PutProperty COM interfaces with > IE. ... ie.Height = 600 > > Actually changes IE's height. > > ie.Height > 600 > Reports it. > But ... > print ie.GetProperty('Height')

[python-win32] How to use GetProperty and PutProperty COM interface in IE?

2007-05-30 Thread Richard Bell
I'm having trouble using the GetProperty and PutProperty COM interfaces with IE. Example: >>> import win32com.client >>> ie = win32com.client.Dispatch('InternetExplorer.Application') >>> ie.visible >>> ie.Navigate('www.google.com') So there's an IE with a loaded page. >>> dir(ie) ['CLSID', 'Cli

Re: [python-win32] Win32 COM cache problem

2007-05-30 Thread Mark Hammond
That is a huge amount of data, and I don't have time to digest it. I'm going to need help to work out why things are happening like this, otherwise I simply am not going to find the time myself. Mark > -Original Message- > From: Marc-André Belzile [mailto:[EMAIL PROTECTED] > Sent: Thursd

Re: [python-win32] Error when trying to open a Microsoft Project file

2007-05-30 Thread Paul Koning
> "Tim" == Tim Roberts <[EMAIL PROTECTED]> writes: >> Can anyone tell me why I'm getting this error message? Tim> Yes, I can. You are trying to open a file name with a tab Tim> character in it. That is, your file name is C colon tab E S T Tim> dot M P P. Tim> Use a.FileOpen( "C:\\test

Re: [python-win32] Getting HRESULT back from a com automation

2007-05-30 Thread Richard Bell
The GenPY output for IE contains two _dispid_to_func list: _dispid_to_func_ = { 101 : "OnNavigateComplete", 103 : "OnQuit", 201 : "OnFrameNavigateComplete", 108 : "OnProgressChange",

Re: [python-win32] Error when trying to open a Microsoft Project file

2007-05-30 Thread Daryl Spitzer
D'oh! That's embarrasing. a.FileOpen( r'C:\test.mpp' ) ...works too. I should have clued in to the double backslashes in the path in the error. (I guess it goes without saying that I don't use Python on Windows very often.) Thanks Tim. -- Daryl On 5/30/07, Tim Roberts <[EMAIL PROTECTED]>

Re: [python-win32] Error when trying to open a Microsoft Project file

2007-05-30 Thread Tim Roberts
Daryl Spitzer wrote: > I'm trying to open a Microsoft Project file using the following: > > from win32com.client import Dispatch a=Dispatch("MSProject.Application") a.Visible=1 a.FileOpen("C:\test.mpp") > > ...but I get this error message. > > Traceback (most re

Re: [python-win32] Win32 COM cache problem

2007-05-30 Thread Marc-André Belzile
The buffer overflow occurs after the __init__file.py has been re-created: 1:40:02 PM XSI.exe:3836QUERY INFORMATION C:\Python25\lib\site-packages\win32com\gen_py\__init__.py SUCCESS Attributes: A 1:40:02 PM XSI.exe:3836OPEN C:\Python25\lib\site-packages\win32c

[python-win32] Error when trying to open a Microsoft Project file

2007-05-30 Thread Daryl Spitzer
I'm trying to open a Microsoft Project file using the following: >>> from win32com.client import Dispatch >>> a=Dispatch("MSProject.Application") >>> a.Visible=1 >>> a.FileOpen("C:\test.mpp") ...but I get this error message. Traceback (most recent call last): File "", line 1, in File "", li

Re: [python-win32] Win32 COM cache problem

2007-05-30 Thread Thomas Heller
Marc-André Belzile schrieb: > I dig a bit more and it appears that the python win32 com module requires all > target typelibs to be in the app current directory. Otherwise the cache is > systematically re-generated anytime a new scripting engine is created. > > Am I doing something wrong ? Than

Re: [python-win32] Win32 COM cache problem

2007-05-30 Thread Marc-André Belzile
Sorry, the code is rather: pythonEngine->AddTypeLib( theLibGUID, dwLibMajorVersion, dwLibMinorVersion, SCRIPTTYPELIB_ISCONTROL ); -mab -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Marc-André Belzile Sent: May 30, 2007 11:19 AM To: Mark Hammond; pyt

Re: [python-win32] Win32 COM cache problem

2007-05-30 Thread Marc-André Belzile
That's odd, if I copy the tlb in the current folder then the __init__.py is not recreated: 10:33:14 AM XSI.exe:3896QUERY INFORMATION C:\Python25\lib\site-packages\win32com\gen_py\__init__.py SUCCESS Attributes: A 10:33:14 AM XSI.exe:3896QUERY INFORMATION C: