Connecting to Windows desktops remotely was made possible with Remote Desktop Connection. But if we do not have an installation of the program, there is another way to do it by connecting via the web. This is made possible with Remote Desktop Web Connection. You only need to download this and install it in order to run the Remote Desktop Connection inside a browser. The installer will extract the necessary files (by default in c:\inetpub\wwwroot\tsweb) and libraries including a default.htm file that contains basically all the code that you need to connect remotely. Make sure you have IIS (Internet Information Server) running though since you will be connecting remotely using a browser.
Using Google Chrome and Firefox are pretty useless since there is the issue of ActiveX. So if you are a total newbie or you do not care wihch browser you would use to run the default.htm, use Internet Explorer right away. Go to http://localhost/tsweb/default.htm to load the page. By default, the page contains a form that will let you input the server and a connect button to connect to the server. If you need to automate connection without submitting the form you use the following HTML code to load the activeX object.
<OBJECT language="vbscript" ID="MsRdpClient" CLASSID="CLSID:9059f30f-4eb1-4bd2-9fdc-36f43a218f4a" CODEBASE="msrdp.cab#version=5,2,xxxx,0"></OBJECT>
Then use the following VBScript code
MsRdpClient.FullScreen = TRUE
resWidth = screen.width
resHeight = screen.height
MsRdpClient.DesktopWidth = resWidth
MsRdpClient.DesktopHeight = resHeight
MsRdpClient.Width = resWidth
MsRdpClient.Height = resHeight
MsRdpClient.server = "ip"
MsRdpClient.username = "username"
MsRdpClient.AdvancedSettings.ClearTextPassword = "password"
MsRdpClient.AdvancedSettings2.RDPPort = "3389"
The code above opens the Remote Desktop Web Connection in Full Screen, it will occupy every space inside the browser. You can also notice that there is an option for setting the port. By default, the port is set at 3389 but desktops have the option to change the port for remote connections so just change the value if you are listening to a server in which the port is not set to its default.