打开系统代理设置:
OpenControlWindow(4);
打开 Internet 选项面板函数实现:
public static bool OpenControlWindow(int TabIndex)
{
// control.exe inetcpl.cpl
try
{
string cmd = "shell32.dll,Control_RunDLL inetcpl.cpl";
if (TabIndex > 0)
{
cmd += ",," + TabIndex;
}
Process process = Process.Start("rundll32", cmd);
if (process != null)
{
process.Dispose();
}
return true;
}
catch (Exception)
{
return false;
}
}