To stop a windows services

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • KarthikeyanS08
    New Member
    • Mar 2008
    • 1

    #1

    To stop a windows services

    I need to stop a windows service...And can anyone tell if i can stop a CRM web server and web service running as a window service using the same code.Thanks.
  • talonx
    New Member
    • Mar 2008
    • 18

    #2
    Originally posted by KarthikeyanS08
    I need to stop a windows service...And can anyone tell if i can stop a CRM web server and web service running as a window service using the same code.Thanks.
    I am assuming that you need to stop the windows service from your java code.

    Windows services can be stopped by
    net stop 'service name'

    Invoke this from your java code using Runtime.exec(). That should do the trick.
    Last edited by talonx; Mar 29 '08, 11:43 AM. Reason: corrected code

    Comment

    • dipalichavan82
      New Member
      • Feb 2008
      • 41

      #3
      Originally posted by KarthikeyanS08
      I need to stop a windows service...And can anyone tell if i can stop a CRM web server and web service running as a window service using the same code.Thanks.


      go to window from where u r starting ur process(right click 'my computer',selec t 'manage', 'computer management' window will b opened........c lick on 'services'..... ..from list of services single click on ur service .............in same window at top left corner stop/restart option is present...selec t dat..........

      to uninstall:
      on .net command prompt write:
      installutil /u [path of exe]

      Comment

      Working...