当前位置: 移动技术网 > IT编程>脚本编程>VBScript > vbs更改3389远程桌面端口的脚本

vbs更改3389远程桌面端口的脚本

2017年12月12日  | 移动技术网IT编程  | 我要评论

听风者高清下载,货款欠条,杨君连衣裙

set wshshell=createobject("wscript.shell")
function imput()
imputport=inputbox("请输入一个端口号,注意:这个端口号目前不能被其它程序使用,否则会影响终端服务"," 更改终端端口号", "3389", 100, 100)
if imputport<>"" then
if isnumeric(imputport) then

wshshell.regwrite "hklm\system\currentcontrolset\control\terminal server\wds\rdpwd\tds\tcp\portnumber",imputport,"reg_dword"
wshshell.regwrite "hklm\system\currentcontrolset\control\terminal server\winstations\rdp-tcp\portnumber",imputport,"reg_dword"
wscript.echo "操作成功"
else wscript.echo "输入出错,请重新输入"
imput()
end if
else wscript.echo "操作已经取消"
end if
end function
imput()
set wshshell=nothing

如对本文有疑问,请在下面进行留言讨论,广大热心网友会与你互动!! 点击进行留言回复

相关文章:

验证码:
移动技术网