How to delete service (with space in its name)?

By adu123 ยท 5 replies
Aug 3, 2008
  1. How can I delete a service with space in its name using cmd command?

    I know sc delete <service name> won't delete the service since it has a space in its name.

    Any help are appreciated:)

    Thanks in advance.

  2. raybay

    raybay TS Evangelist Posts: 7,241   +10

    Type Cmd /?
    to get a full list of all commands, then enter the selected command and read the instructions.
  3. adu123

    adu123 TS Maniac Topic Starter Posts: 278

    I tried, but it didn't seems help.....
  4. xxdanielxx

    xxdanielxx TS Booster Posts: 1,069

    Hey just use the script below just take away the x on [xcode] and [x/code] it does not matter if there is a space

    We need to get rid of one of the services running on your machine. To do this, copy (Ctrl +C) and paste (Ctrl +V) the text in the code box below to Notepad.

    @echo off
    sc stop enter service name
    sc delete enter service name
    del service.cmd and exit

    Save it to your desktop as File name: service.cmd
    Save as type: All Files

    Once done, double click service.cmd to run it. A command window will open briefly, then close. This is quite normal.
  5. Justin

    Justin TS Rookie Posts: 942

    If you encapsulate the service name in quotes it should work.
  6. adu123

    adu123 TS Maniac Topic Starter Posts: 278

    Thanks, got it!
Topic Status:
Not open for further replies.

Similar Topics

Add your comment to this article

You need to be a member to leave a comment. Join thousands of tech enthusiasts and participate.
TechSpot Account You may also...