JamesDover Posted May 5, 2009 Posted May 5, 2009 This is what i have so far but I am unable to install it as a service silently. Is there a switch or something I'm missing? Cheers If FileExists("C:\Program Files\Tightvnc\WinVNC.exe") Then RunWait("C:\Program Files\Tightvnc\WinVNC.exe -install", "", @SW_HIDE) Sleep(500) Else EndIf
MrMitchell Posted May 5, 2009 Posted May 5, 2009 (edited) Are you sure this is an AutoIt problem and not a WinVNC problem? Anyway after you install it as a service the popup window goes away within a few seconds. Add: I was actually trying this at work a couple weeks ago using "sc create", but I couldn't get it working. Still trying... Edited May 5, 2009 by MrMitchell
WideBoyDixon Posted May 5, 2009 Posted May 5, 2009 http://msdn.microsoft.com/en-us/library/ms682450(VS.85).aspxWBD [center]Wide by name, Wide by nature and Wide by girth[u]Scripts[/u]{Hot Folders} {Screen Calipers} {Screen Crosshairs} {Cross-Process Subclassing} {GDI+ Clock} {ASCII Art Signatures}{Another GDI+ Clock} {Desktop Goldfish} {Game of Life} {3D Pie Chart} {Stock Tracker}[u]UDFs[/u]{_FileReplaceText} {_ArrayCompare} {_ToBase}~ My Scripts On Google Code ~[/center]
MrMitchell Posted May 5, 2009 Posted May 5, 2009 SC.exe is VERY picky, but finally got it working. Haven't tested if the service actually works though I know it will start using "sc start winvnc" or after reboot, but it still needs a default password set. So...I think you might need to find a way to create a .vnc file then have your new service use it. I'm not sure how WinVNC works like that though so good luck! sc create winvnc binPath= "\"C:\Program Files\TightVNC\WinVNC.exe\" -service" start= auto DisplayName= "VNC Server" type= own type= interact Result: [sC] CreateService SUCCESS
JamesDover Posted May 14, 2009 Author Posted May 14, 2009 Nice I never thought about going in that direction. I'll give it a try. To set the default password I just use regwrite before running the service. RegWrite("HKEY_CURRENT_USER\Software\ORL\WinVNC3", "Password", "REG_BINARY", Binary('0x' & $Password)) RegWrite("HKEY_CURRENT_USER\Software\ORL\WinVNC3", "PasswordViewOnly", "REG_BINARY", Binary('0x' & $PasswordViewOnly))
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now