0

I am trying to install TightVnC using a bat file. the code i have below will not work. I copied the below code minus the line with the http address in it. It was set up to use a local file for the .msi installer. But i have to install this on 200 computers and its just a pain in the back side to download it on each computer. Is there a way to make this work with out downloading the file? or have it download for me?

@echo off 
echo.
echo Iinstall TightVNC
echo.
echo.
echo COPYING SETUP FILES... ... .. .
copy http://www.tightvnc.com/download/2.7.10/tightvnc-2.7.10-setup-64bit.msi C:\Users\%username%\Desktop\
echo.
echo.
echo INSTALLING AND CONFIGURING ... ... ... .. . .
msiexec /i C:\Users\%username%\Desktop\tightvnc-2.7.10-setup-64bit.msi /quiet /norestart ADDLOCAL="Server,Viewer" VIEWER_ASSOCIATE_VNC_EXTENSION=1 SERVER_REGISTER_AS_SERVICE=1 SERVER_ADD_FIREWALL_EXCEPTION=1 VIEWER_ADD_FIREWALL_EXCEPTION=1 SERVER_ALLOW_SAS=1 SET_USEVNCAUTHENTICATION=1 VALUE_OF_USEVNCAUTHENTICATION=1 SET_PASSWORD=1 VALUE_OF_PASSWORD=c0nn3cT. SET_USECONTROLAUTHENTICATION=1 VALUE_OF_USECONTROLAUTHENTICATION=1 SET_CONTROLPASSWORD=1 VALUE_OF_CONTROLPASSWORD=C0nTr0l.
echo.
echo.
echo CLEANING UP .. .. .
del C:\Users\%username%\Desktop\tightvnc-2.7.10-setup-64bit.msi
echo.
echo.
echo FINISHED!

pause
Donavon
  • 51
  • 1
  • 1
  • 12
  • 3
    You should be getting a server, adding all your machines to a domain, and pushing this out through group policy. – Dark Falcon Jan 13 '15 at 20:39
  • What specifically does *will not work* mean? You've posted code that you've said is *not the same* as what you're using, and not explained what the issue is with that code that you *have not included*. How exactly do you expect us to help you? – Ken White Jan 13 '15 at 21:14
  • @KenWhite the code is what i am using and it doesn't work. The code that i had that did worked used a local copy of the file not a url. – Donavon Jan 13 '15 at 23:14
  • As I said, you need to be more specific. What does *it doesn't work* mean? Do you get an error message? Does it copy the wrong file? Or copy the file to the wrong location? Does your computer crash? If you don't understand the need for more details, call your doctor's office and say "My body doesn't work. Here's my picture when I was younger. I look sort of like that now. What's wrong, and what treatment do you prescribe to make me better?" and see if the doctor is willing to answer without more details. **If you want help, be specific in describing the problem.** "it doesn't work" is useless. – Ken White Jan 13 '15 at 23:18
  • You clearly can't use `copy` to retrieve a file from a web site, so you would have to use something like `wget` or another command line utility that is capable of retrieving the file before you can run it locally, or just download it yourself first, and put it in a network location or wherever your batch file is located so the batch file can execute it. – Ken White Jan 13 '15 at 23:20
  • @KenWhite Thank you for that info that is exactly what i was trying to understand. I was unclear on how the whole request from a website worked. Thank you! – Donavon Jan 14 '15 at 15:14

0 Answers0