private void button_Click(object sender EventArgs e)
{
//打开注册表键
MicrosoftWinRegistryKey rk = MicrosoftWinRegistryCurrentUserOpenSubKey(@Software\Microsoft\Windows\CurrentVersion\Internet Settings true);
//设置代理可用
rkSetValue(ProxyEnable );
//设置代理IP和端口
rkSetValue(ProxyServer thistextBoxTextToString() + : + thistextBoxTextToString());
rkClose();
FactoryExecuteNonQuery(update IP set area= where address= + str + );
thisdataGridViewDataSource = FactoryGetDataTable(select * from ip);
MessageBoxShow(成功!!!);
}
private void button_Click(object sender EventArgs e)
{
//打开注册表键
MicrosoftWinRegistryKey rk = MicrosoftWinRegistryCurrentUserOpenSubKey(@Software\Microsoft\Windows\CurrentVersion\Internet Settings true);
//设置代理不可用
rkSetValue(ProxyEnable ); rkClose(); MessageBoxShow(成功!!!);
}