Results 1 to 6 of 6
  1. #1
    Star Lounger MarkAtHome's Avatar
    Join Date
    Feb 2001
    Location
    New Jersey, USA
    Posts
    85
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Determine/close Outlook via DOS (XP/2002)

    For backup purposes, I need to determine, via WinXP Pro's command prompt/DOS (batch file)., whether Outllook is loaded in memory and if it is, I need to be able to close Outlook. Anyone know how I can do this?

  2. #2
    5 Star Lounger
    Join Date
    May 2001
    Location
    Washington, USA
    Posts
    750
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Determine/close Outlook via DOS (XP/2002)

    I used to be pretty good with DOS, but have gotten rusty. Any case, I don't think you can do that. Have you considered using the scripting engine? Off hand I don't know the details of how this would work, but I'm pretty sure it would work.

  3. #3
    Plutonium Lounger Leif's Avatar
    Join Date
    Dec 2000
    Location
    U.K.
    Posts
    14,010
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Determine/close Outlook via DOS (XP/2002)

    What operating system? I believe the Resource Kits for NT4 and W2K have a KILL utility for closing applications - whether or not it would matter if you ran the command and it wasn't running, I'm not sure.

  4. #4
    5 Star Lounger
    Join Date
    Dec 2002
    Location
    Perth, Western Australia, Australia
    Posts
    730
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Determine/close Outlook via DOS (XP/2002)

    If that KILL exists and works, it seems the simplest solution - no need to check for OL, just make sure it's gone.

    If KILL isn't available, or you can't use it indiscriminately, I think it will be difficult or impossible to do what you want in a batch file.

    An alternative route is to a look at <!post=AutoIt, 221780>AutoIt<!/post>. If you're comfy with batch files, then AutoIt should be manageable. You may have to adopt a slightly different process though. Like use a script under windows to check for & kill OL, and it then start off your BU batch file.
    <font face="Comic Sans MS" color="blue">TimOz</font>
    <img src=/S/flags/Finland.gif border=0 alt=Finland width=30 height=18> <img src=/S/flags/Australia.gif border=0 alt=Australia width=30 height=18>

  5. #5
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Determine/close Outlook via DOS (XP/2002)

    So you want to close Outlook with a batch file? Check out the VBScript solution in <!post=Post #59227,59227>Post #59227<!/post>. To run .vbs files from the command prompts, cscript.exe should be in the default path.

  6. #6
    5 Star Lounger
    Join Date
    May 2001
    Location
    Washington, USA
    Posts
    750
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Determine/close Outlook via DOS (XP/2002)

    This is a much cleaner approach. As I understand Kill, it doesn't use the application shutdown, it just terminates the execution. This could cause corruption. In any case, Outlook will know it was not shut down properly and will start up slower next time as it runs integrety checks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •