Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > win32com.client.Dispatch - understanding error messages

Reply
Thread Tools

win32com.client.Dispatch - understanding error messages

 
 
mirandacascade@yahoo.com
Guest
Posts: n/a
 
      07-18-2006
O/S : Win2K
vsn of Python: 2.4

Hoping to find information that provide information about error
messages being encountered.

Pythonwin session:

>>> import win32com.client
>>> blah = win32com.client.Dispatch('MSXML2.XMLHTTP')
>>> blah.open("POST", "12.5.81.49/crg_cbsil_vtest_52/crg.aspx", 0)

Traceback (most recent call last):
File "<interactive input>", line 1, in ?
File "<COMObject MSXML2.XMLHTTP>", line 4, in open
com_error: (-2147352567, 'Exception occurred.', (0, None, None, None,
0, -2147467259), None)

I tried various combinations in Google involving
"win32com.client.Dispatch", "MSXML2", "XMLHTTP" and the 2 different
error codes: -2147352567 and -2147467259. So far, I haven't been able
to locate anything that has helped me zero in on the error.

The fact that no error was issued after the blah = ... statement plus
the fact that as soon as I typed the '(' character after blah.open,
that the arguments for the open method were displayed; those two things
make me think that the COM object is installed/registered on the
workstation. Is that a reasonable conclusion?

I observed that there are a few other similarly named objects/methods,
so I tried them as well. The error messages reference some different
dll's, but those error message seemed as inscrutable as the first set
of error messages above.

>>> blah = win32com.client.Dispatch('MSXML2.XMLHTTP.4.0')
>>> blah.open("POST", "12.5.81.49/crg_cbsil_vtest_52/crg.aspx", 0)

Traceback (most recent call last):
File "<interactive input>", line 1, in ?
File "<COMObject MSXML2.XMLHTTP.4.0>", line 4, in open
com_error: (-2147352567, 'Exception occurred.', (0, 'msxml4.dll',
'System error: -2147012890.\r\n', None, 0, -2147012890), None)

and

>>> blah = win32com.client.Dispatch('MSXML2.ServerXMLHTTP')
>>> blah.open("POST", "12.5.81.49/crg_cbsil_vtest_52/crg.aspx", 0)

Traceback (most recent call last):
File "<interactive input>", line 1, in ?
File "<COMObject MSXML2.ServerXMLHTTP>", line 4, in open
com_error: (-2147352567, 'Exception occurred.', (0, 'msxml3.dll',
'Unspecified error\r\n', None, 0, -2147467259), None)

Also tried varying the 3rd argument...instead of using 0 to represent
False, I tried:

>>> False

False
>>> blah = win32com.client.Dispatch('MSXML2.XMLHTTP')
>>> blah.open("POST", "12.5.81.49/crg_cbsil_vtest_52/crg.aspx", False)

Traceback (most recent call last):
File "<interactive input>", line 1, in ?
File "<COMObject MSXML2.XMLHTTP>", line 4, in open
com_error: (-2147352567, 'Exception occurred.', (0, None, None, None,
0, -2147467259), None)

So, if possible, it would be nice to know two different types of
things:
1) what steps to take to correct these errors
2) where one can locate information about these types of errors

 
Reply With Quote
 
 
 
 
Duncan Booth
Guest
Posts: n/a
 
      07-18-2006
wrote:

>>>> False

> False
>>>> blah = win32com.client.Dispatch('MSXML2.XMLHTTP')
>>>> blah.open("POST", "12.5.81.49/crg_cbsil_vtest_52/crg.aspx", False)


Does using an absolute URL for the url parameter help any? You've specified
a relative URL (i.e. the folder 12.5.81.49 under the current location).

 
Reply With Quote
 
 
 
 
mirandacascade@yahoo.com
Guest
Posts: n/a
 
      07-18-2006
Duncan Booth wrote:
> wrote:
>
> Does using an absolute URL for the url parameter help any? You've specified
> a relative URL (i.e. the folder 12.5.81.49 under the current location).


I don't know the answer to that question. I know that when I'm on the
same workstation and I copy/paste the string that is the url parameter
into my browser and press Enter, that a reply appears within the
browser, and that reply has content that suggests that the browser app
was able to 'talk' to an application on the other end. The error
message being received in reply to the open method make me think that
the open method wasn't able to talk to any app on the other end. I'm
not sure what can be inferred from that observation other than the url
parameter appears to be valid when it is used in a browser application.

 
Reply With Quote
 
Duncan Booth
Guest
Posts: n/a
 
      07-18-2006
wrote:

> Duncan Booth wrote:
>> wrote:
>>
>> Does using an absolute URL for the url parameter help any? You've
>> specified a relative URL (i.e. the folder 12.5.81.49 under the
>> current location).

>
> I don't know the answer to that question. I know that when I'm on the
> same workstation and I copy/paste the string that is the url parameter
> into my browser and press Enter, that a reply appears within the
> browser, and that reply has content that suggests that the browser app
> was able to 'talk' to an application on the other end. The error
> message being received in reply to the open method make me think that
> the open method wasn't able to talk to any app on the other end. I'm
> not sure what can be inferred from that observation other than the url
> parameter appears to be valid when it is used in a browser
> application.
>

Are you really sure that the browser isn't making guesses about what you
meant and correcting the error for you? Does what remains in the address
bar when the page is retrieved really match *exactly* what you copied and
pasted?
 
Reply With Quote
 
mirandacascade@yahoo.com
Guest
Posts: n/a
 
      07-19-2006

Duncan Booth wrote:
> Are you really sure that the browser isn't making guesses about what you
> meant and correcting the error for you? Does what remains in the address
> bar when the page is retrieved really match *exactly* what you copied and
> pasted?


Thank you for that pointer. The answer is: no, it does not match
exactly. The browser did indeed, as you surmised, make a guess and
correct the error. The browser added 'http://' to the beginning. When
'http://' gets added to the beginning of the url parameter, all is well.

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
There are no more messages on this topic. All messages in this topic may have expired or been deleted Coach 02 Computer Support 1 03-12-2007 03:44 PM
absence of router advertisment messages in reponse to roiuter solicitation messages sonia sainani Software 0 10-20-2006 09:20 AM
Need help in understanding gdb messages O.R.Senthil Kumaran C Programming 2 09-23-2005 08:17 AM
i sent 2 messages about double messages monique Computer Support 0 11-27-2004 07:18 PM
will all these messages cause a problem . I am a new subscriber and my computer is downloading 100,000 messages. Will this cause any kind of a problem with my ability to store other items?? Camille White Camille White Computer Support 9 11-08-2004 01:13 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57