Tim,

Thanks for the advice. Unfortunately I'm not a C developer - I would
have no idea how to go about this. I was hoping that there would be an
easy way to use these functions purely in Python. 

The problem is I've no idea how to use the syntax - I'm quite unfamiliar
with how you provide a value for AUTOPROXY_OPTIONS - I had hoped that I
could provide a tuple of values which match the arguments expected by
the function (as desctribed by MSDN) however there seems to be some
other trick I am missing. 

PS. Unfortunately I have no control over the legal disclaimers - I work
for an institution which is overly fond of such things. I'm sure they
are nonsense in all but a few very spesific circumstances.

-----Original Message-----
From: python-win32-bounces+fadhley.salim=uk.calyon....@python.org
[mailto:python-win32-bounces+fadhley.salim=uk.calyon....@python.org] On
Behalf Of Tim Roberts
Sent: 07 July 2009 17:44
To: Python-Win32 List
Subject: Re: [python-win32] Examples of Win32Inet use

Fadhley Salim wrote:
> Thanks Roger,
>
> Would you care to comment about how to get the 3rd line of my script 
> working? I'm guessing that the fault lies with my use of the Proxy 
> options (the tuple argument) - this is supposed to map onto 
> WINHTTP_AUTOPROXY_OPTIONS ( 
> http://msdn.microsoft.com/en-us/library/aa384123(VS.85).aspx ) - I'm 
> just not sure how to make this work in Python!
>
> import win32inet
> hSession = win32inet.WinHttpOpen ("foo 1.0", 0, "", "", 0) proxy = 
> win32inet.WinHttpGetProxyForUrl( hSession, "http://www.foo.com";,
> (0,0,u"",None,0,1) )
> print proxy
>   

Are you sure this works in C?  Have you tried it?  In
WINHTTP_AUTOPROXY_OPTIONS, you aren't telling it which mechanisms to try
in order to get the proxy auto-config file.  I would have guess you need
to specify at least WINHTTP_AUTOPROXY_AUTO_DETECT.

> Disclaimer CALYON UK:
> This email does not create a legal relationship between any member of
the ...
>   

I have to say, your messages carry the most obnoxious legal disclaimer
I've encountered in a long, long time.  The efficacy of such disclaimers
has never been established in court, to my knowledge.

--
Tim Roberts, t...@probo.com
Providenza & Boekelheide, Inc.

_______________________________________________
python-win32 mailing list
python-win32@python.org
http://mail.python.org/mailman/listinfo/python-win32
Disclaimer CALYON UK:
This email does not create a legal relationship between any member of the 
Cr=E9dit Agricole group and the recipient or constitute investment advice. 
The content of this email should not be copied or disclosed (in whole or 
part) to any other person. It may contain information which is 
confidential, privileged or otherwise protected from disclosure. If you 
are not the intended recipient, you should notify us and delete it from 
your system. Emails may be monitored, are not secure and may be amended, 
destroyed or contain viruses and in communicating with us such conditions 
are accepted. Any content which does not relate to business matters is not 
endorsed by us.

Calyon is authorised by the Comit=e9 des Etablissements de Cr=e9dit et des
Entreprises d'Investissement (CECEI) and supervised by the Commission Bancaire
in France and subject to limited regulation by the Financial Services Authority.
Details about the extent of our regulation by the Financial Services Authority
are available from us on request. Calyon is incorporated in France with limited
liability and registered in England & Wales. Registration number: FC008194.
Registered office: Broadwalk House, 5 Appold Street, London, EC2A 2DA.
Disclaimer CALYON France:
This message and/or any attachments is intended for the sole use of its 
addressee.
If you are not the addressee, please immediately notify the sender and then 
destroy the message.
As this message and/or any attachments may have been altered without our 
knowledge, its content is not legally binding on CALYON Crédit Agricole CIB.
All rights reserved.

Ce message et ses pièces jointes est destiné à l'usage exclusif de son 
destinataire.
Si vous recevez ce message par erreur, merci d'en aviser immédiatement 
l'expéditeur et de le détruire ensuite.
Le présent message pouvant être altéré à notre insu, CALYON Crédit Agricole CIB 
ne peut pas être engagé par son contenu.
Tous droits réservés.
_______________________________________________
python-win32 mailing list
python-win32@python.org
http://mail.python.org/mailman/listinfo/python-win32

Reply via email to