I had a terrific time setting up Visual Studio 2005 Remote Debugger Setup in Vista.When we run MSVSMON.EXE, It will try to configure the firewall but for me it gave an error message stating "Could not configure the Windows firewall" and sometimes I got "Incorrect function".
Finally I found the solution, thanks to MSDN forms, http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=720298&SiteID=1. The solution is to enable the ports in the firewall using netsh commands.
To enabling the remote debugging, do the following.
netsh advfirewall firewall add rule name="Microsoft Visual Studio Remote Debugger - UDP 137" dir=in action=allow enable=yes localport=137 protocol=udp netsh advfirewall firewall add rule name="Microsoft Visual Studio Remote Debugger - UDP 138" dir=in action=allow enable=yes localport=138 protocol=udp netsh advfirewall firewall add rule name="Microsoft Visual Studio Remote Debugger - TCP 139" dir=in action=allow enable=yes localport=139 protocol=tcp netsh advfirewall firewall add rule name="Microsoft Visual Studio Remote Debugger - TCP 445" dir=in action=allow enable=yes localport=445 protocol=tcp
Run MSVSMON.EXE again, you are good to go.