Solved

Change Proxy Setting in Internet OPtions

Posted on 2009-07-04
2
307 Views
Last Modified: 2012-06-21
HI
I am using VB.net 2005
I am tring to drill down through the control panel / internet options /  connections / lan settings and then read & write to the proxy server checkbox  I would rather not touch the registry directly.

It was easy to open the Internet Options dialog (see code below),  but I have been unsuccessful in getting the handle for this dialog.  I have been trying findwindowex but that does not seem to work for me.

I would like to know how to get the handle for the "Internet Properties" window.   All help would be greatly appreciated

Thanks!


Dim VPN As Process = System.Diagnostics.Process.Start("inetcpl.cpl")

Open in new window

0
Comment
Question by:peispud
2 Comments
 
LVL 12

Accepted Solution

by:
needo_jee earned 500 total points
ID: 24777239
hi,

I am not sure about the way you are trying to change proxy settings.. however, I think you can change it via registry settings something like this..

Dim regKey As RegistryKey
regKey = Registry.CurrentUser.OpenSubKey("Software\Microsoft\Windows\CurrentVersion\Internet Settings", True)
regKey.SetValue("ProxyEnable", True, RegistryValueKind.DWord)

-thanks
0
 

Author Comment

by:peispud
ID: 24777318
The computer is for work purposes and the registry is locked.  I manually have to change the proxy settings several times a day.  It's a real hassle

If I can get the handles of that checkbox then I can use sendapi to turn on/off the proxy.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
1.0 - Introduction Converting Visual Basic 6.0 (VB6) to Visual Basic 2008+ (VB.NET). If ever there was a subject full of murkiness and bad decisions, it is this one!   The first problem seems to be that people considering this task of converting…

860 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question