Solved

How can I install/unistall windows  service using command line ?

Posted on 2008-10-14
4
5,213 Views
Last Modified: 2008-11-04
I have developped a service:
:
myService.exe (which is a service) and located in windows/system32

How can I install/unistall  this service using command line ?
(I am doing it through Inno setup, but I need to do it through command line)

regards
0
Comment
Question by:yarek
  • 2
4 Comments
 
LVL 2

Expert Comment

by:jlundfelt
ID: 22713926
You can do a NET STOP MyService and the a REG DELETE

e.g.

REG DELETE HKLM\System\CurrentControlSet\Services\MyService
0
 

Author Comment

by:yarek
ID: 22713945
I need to INSTALL it : NOT TO START IT !
0
 
LVL 2

Expert Comment

by:jlundfelt
ID: 22715535
Well if you need to install it, just add the registry keys you need with REG ADD, or an installer (Wise, Nullsoft,etc..) and start it.

Look at any existing service to see what keys you need. But if its just a process, it won't start correctly.
0
 
LVL 83

Accepted Solution

by:
oBdA earned 500 total points
ID: 22724954
You can do that with sc.exe:
How to create a Windows service by using Sc.exe
http://support.microsoft.com/kb/251192/en-us
0

Featured Post

Swamped with email signature updates?

Have you been given a load of changes to make to your users’ email signatures? Having to manually implement multiple signatures for every department? Let Exclaimer save you from being swamped with email signature updates!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Excel Error per WinZip Add-In 9 59
forgot pst password 2 40
Windows 10 Mail Sync Error 6 30
Total Commander set home directory with lock to go up 6 19
Citrix XenApp, Internet Explorer 11 set to Enterprise Mode and using central hosted sites.xml file.
The use of stolen credentials is a hot commodity this year allowing threat actors to move laterally within the network in order to avoid breach detection.
This video Micro Tutorial explains how to clone a hard drive using a commercial software product for Windows systems called Casper from Future Systems Solutions (FSS). Cloning makes an exact, complete copy of one hard disk drive (HDD) onto another d…
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now