PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Autres forums > Forum Programmation & Conception > comp.lang.ruby > How to get and set the proxy of IE?
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
How to get and set the proxy of IE?

Réponse
 
LinkBack Outils de la discussion
Vieux 10/03/2008, 12h04   #1
Wu Junchen
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut How to get and set the proxy of IE?

I want to let my program connect to internet using the proxy setting of
IE,and I spent some time to find it in google,but nothing was found.Is
there some way to do it?
Any will be appreciated!
--
Posted via http://www.ruby-forum.com/.

  Réponse avec citation
Vieux 10/03/2008, 14h23   #2
Siep Korteling
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: How to get and set the proxy of IE?

Wu Junchen wrote:
> I want to let my program connect to internet using the proxy setting of
> IE,and I spent some time to find it in google,but nothing was found.Is
> there some way to do it?
> Any will be appreciated!


require 'win32/registry'

def get_proxy
path='Software\Microsoft\Windows\CurrentVersion\In ternet Settings'
type, value
=Win32::Registry::HKEY_CURRENT_USER.open(path).rea d('Server')
return value
end

Untested, on my laptop the proxy is handled in another way (wininet.dll
?)

Regards,

Siep
--
Posted via http://www.ruby-forum.com/.

  Réponse avec citation
Vieux 10/03/2008, 14h28   #3
Siep Korteling
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: How to get and set the proxy of IE?

Siep Korteling wrote:
> Wu Junchen wrote:
>> I want to let my program connect to internet using the proxy setting of


> Regards,
>
> Siep


Should be:

require 'win32/registry'

def get_proxy
path = 'Software\Microsoft\Windows\CurrentVersion\Interne t Settings'
type, value =
Win32::Registry::HKEY_CURRENT_USER.open(path).read ('ProxyServer') #!
return reg_value
end

regards,

Siep

--
Posted via http://www.ruby-forum.com/.

  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 00h31.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,10301 seconds with 11 queries