Active Directory: Remote Desktop
This did take me sometime to figure, but it is all figured!
In case if you ever shipped a comuter before enabling “terminal service” on that machine, you can still do that.
All you have to do is copy the following code into a notepad and save it as “turn_on.cmd” or whatever… and then type in CMD the following:
[code]
turn_on computername
[/code]
and that’s all… and here is the actual script to copy to the turn_on.cmd file
[code]
@echo off
setlocal
if {%1}=={} goto syntax
:loop
if {%1}=={} goto finish
set remote=”\\%1\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server”
shift
reg.exe ADD %remote% /v fDenyTSConnections /t REG_DWORD /d 0 /f>nul 2>&1
if NOT %ERRORLEVEL% EQU 0 @echo %remote% NOT found.
goto loop
:syntax
@echo Syntax: RemoteDesktop Computer1 [Computer2 .... Computern]
goto loop
:finish
endlocal
[/code]
If you enjoyed this post, please consider to leave a comment or subscribe to the feed and get future articles delivered to your feed reader.

Comments
No comments yet.
Leave a comment