Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/batch-file/6.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Proxy 批处理/BAT-使用批处理/BAT文件更改代理设置_Proxy_Batch File_Settings - Fatal编程技术网

Proxy 批处理/BAT-使用批处理/BAT文件更改代理设置

Proxy 批处理/BAT-使用批处理/BAT文件更改代理设置,proxy,batch-file,settings,Proxy,Batch File,Settings,有人能教我如何使用.bat文件或建议更改代理设置吗? 老实说,我找不到关于他的好消息 我需要一个.bat文件,该文件将使用特定的代理ip和端口更改我的internet设置(代理) 谢谢Internet Explorer的代理服务器设置存储在注册表中的Software\Microsoft\Windows\CurrentVersion\Internet settings下 使用(自Windows 7起随Windows一起提供),您可以使用: set itemproperty-path“hkcu:So

有人能教我如何使用.bat文件或建议更改代理设置吗? 老实说,我找不到关于他的好消息

我需要一个.bat文件,该文件将使用特定的代理ip和端口更改我的internet设置(代理)


谢谢

Internet Explorer的代理服务器设置存储在注册表中的
Software\Microsoft\Windows\CurrentVersion\Internet settings

使用(自Windows 7起随Windows一起提供),您可以使用:

set itemproperty-path“hkcu:Software\Microsoft\Windows\CurrentVersion\Internet Settings”-name ProxyServer-value“http=proxy-url:port;https=proxy-url:port;ftp=proxy-url:port;socks=proxy-url:port;”-键入字符串


此设置只会影响Internet Explorer,可能需要一个新选项卡,甚至可能需要重新启动IE,尽管这不太可能。

如果您不想安装Powershell,另一个选项是使用该命令

因此,在这种情况下,您应该在批处理脚本中添加:

REG添加“HKCU\Software\Microsoft\Windows\CurrentVersion\Internet设置”/v ProxyServer/d“http=proxy url:port;https=proxy url:port;ftp=proxy url:port;socks=proxy url:port;”/t REG\u SZ/f


有关信息,win32上的Google Chrome也使用代理Internet Explorer设置Chrome/Chrome将使用IE代理设置(即系统设置)
,除非在命令行上指定代理,例如
Chrome.exe”-proxy server=“socks5://localhost:9090“
或-
代理服务器=127.0.0.1:8080
如何为专用代理添加用户名和密码?让我补充一点,与大多数注册表设置不同,此设置可以毫不延迟地工作。双击批处理脚本并立即应用它。如果还想启用代理,请添加以下行:
REG add“HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings”/v proxyienable/d 1/t REG\u DWORD/f
Set ItemProperty:缺少参数“Name”的参数。请指定“System.String”类型的参数,然后重试。第1行字符:91+。。。rnet设置“-name+~~~~~~~+CategoryInfo:InvalidArgument:(:)[Set-ItemProperty],ParameterBindingException+FullyQualifiedErrorId:MissingArgument,Microsoft.PowerShell.Commands.SetItemPropertyCommand