• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1242
  • Last Modified:

Change HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ProxyEnable

Hi,

I need to change this registry key in VBA using a command button? HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ProxyEnable

Any thoughts?

Chris
0
archer1050
Asked:
archer1050
  • 2
1 Solution
 
stevbeCommented:
you could shell a .reg file or try this code out ...

http://www.mvps.org/access/api/api0015.htm

Steve
0
 
inoxCommented:

you can use

    Dim objWSH As Object    
    Set objWSH = CreateObject("WScript.Shell")
    objWSH.RegWrite "HKLM\Software\MyApplication\strValue", "Some string value"

you also can use the
GetSetting, SaveSetting functions:
GetSetting(appname, section, key[, default])
but they are linited to the HKEY_CURRENT_USER key, sufficient for your request
0
 
archer1050Author Commented:
The value is a dword value, will this function still work?
0
 
inoxCommented:

with
objWSH.RegWrite "HKLM\Software\MyApplication\key1", 1234, "REG_DWORD"

you can write integers and read also
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now