jorge Posted July 22, 2003 Posted July 22, 2003 Hey, I'm working on a GUI for apache(webserver), I'd like to start it from a remote pc, sind i can't do it with apache.exe -k start -n"apache2", I was thingking about a service controller, will that alow me to start or stop a service on a other computer? thanx in advance Quote Jorge - http://www.blackdot.be/?page=apache.htm
jorge Posted July 26, 2003 Author Posted July 26, 2003 anyone? Quote Jorge - http://www.blackdot.be/?page=apache.htm
JoeNuvo Posted August 3, 2003 Posted August 3, 2003 try this one http://www.experts-exchange.com/Programming/Programming_Languages/Visual_Basic/Q_10313144.html you will found sample code for remote start/stop service here. Don't want to just copy code to put down here. (wanna give credit to the one whom answer it) Wish this can help. Quote
Administrators PlausiblyDamp Posted August 3, 2003 Administrators Posted August 3, 2003 Didn't read all the link but it seemed to be doing it a very complex way (was it VB6 code?) This may be easier. Dim sc As New System.ServiceProcess.ServiceController sc.MachineName = "RemoteComputerName" sc.ServiceName = "ServiceName" 'Apache2 - or whatever sc.Start() 'Will start it (permissions required) Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
jorge Posted August 3, 2003 Author Posted August 3, 2003 PlausiblyDamp, Don't seem to work when i try it in my small home network? Don't know why, computer name of apache (desktop) Remotecomputer(Dad's pc), Set MachineName "desktop", but nothing hapens :s Quote Jorge - http://www.blackdot.be/?page=apache.htm
Administrators PlausiblyDamp Posted August 3, 2003 Administrators Posted August 3, 2003 will have a look tomorrow - no network here. Does the account you logon to your computer with also exist on the remote computer? If so are the passwords different? finally is the account and administrative account? Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
jorge Posted August 4, 2003 Author Posted August 4, 2003 Yes, both admin acount with the same name and password Quote Jorge - http://www.blackdot.be/?page=apache.htm
Administrators PlausiblyDamp Posted August 4, 2003 Administrators Posted August 4, 2003 Not sure why it shouldn't work - just tried it here in the office ond it worked a charm. It may be worth trying the remote computers IP address instead of it's name (both ways worked here) - may be a WINS / DNS problem. Quote Posting Guidelines FAQ Post Formatting Intellectuals solve problems; geniuses prevent them. -- Albert Einstein
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.