Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    Super Moderator
    Join Date
    May 2002
    Location
    Perth Australia
    Posts
    4,081
    Thanks
    11
    Thanked 99 Times in 97 Posts

    get a handle on running powerpoint presentation

    Hi, I have to write up a quick something to..

    1) download a .pps from an ftp server (noprobs)
    2) stop the running pps presentation (stuck)
    3) start the new (downloaded) version of the pps (depends on 2)

    I can write a batch script to download the lastest PPS and start it with no issues , but not sure how I would close the currently running pps presentation, how would I get a handle on that in a simple batch script ?

    I could use PHP to exec a process viewer and kill all pps processes but that seems really violent and I am sure there is a more elegant solution in say VB or something ... any ideas ?
    resistance is...

    MVC is the current buzz in web application architectures. It comes from event-driven desktop application design and doesn't fit into web application design very well. But luckily nobody really knows what MVC means, so we can call our presentation layer separation mechanism MVC and move on. (Rasmus Lerdorf)

  • #2
    Super Moderator
    Join Date
    May 2002
    Location
    Perth Australia
    Posts
    4,081
    Thanks
    11
    Thanked 99 Times in 97 Posts
    cool , got this one below from http://www.computerperformance.co.uk...ocess_stop.htm

    Code:
    ' ProcessKillLocal.vbs
    ' Sample VBScript to kill a program
    ' Author Guy Thomas http://computerperformance.co.uk/
    ' Version 2.7 - December 2005
    ' ------------------------ -------------------------------'
    Option Explicit
    Dim objWMIService, objProcess, colProcess
    Dim strComputer, strProcessKill
    strComputer = "."
    strProcessKill = "'calc.exe'"
    
    Set objWMIService = GetObject("winmgmts:" _
    & "{impersonationLevel=impersonate}!\\" _
    & strComputer & "\root\cimv2")
    
    Set colProcess = objWMIService.ExecQuery _
    ("Select * from Win32_Process Where Name = " & strProcessKill )
    For Each objProcess in colProcess
    objProcess.Terminate()
    Next
    WSCript.Echo "Just killed process " & strProcessKill _
    & " on " & strComputer
    WScript.Quit
    ' End of WMI Example of a Kill Process
    resistance is...

    MVC is the current buzz in web application architectures. It comes from event-driven desktop application design and doesn't fit into web application design very well. But luckily nobody really knows what MVC means, so we can call our presentation layer separation mechanism MVC and move on. (Rasmus Lerdorf)

  • #3
    Rockstar Coder
    Join Date
    Jun 2002
    Location
    USA
    Posts
    9,074
    Thanks
    1
    Thanked 328 Times in 324 Posts
    Another way if you don't want to kill the process, you can use this program: http://www.autohotkey.com/ To build a macro that will send the key strokes to end PowerPoint and I believe you can get it so it will select the window by the window name. And you can compile your macro into its own little exe. Might be worth looking into, its a cool program nonetheless.
    OracleGuy

  • #4
    Super Moderator
    Join Date
    May 2002
    Location
    Perth Australia
    Posts
    4,081
    Thanks
    11
    Thanked 99 Times in 97 Posts
    cool, checking it out now cheers !
    resistance is...

    MVC is the current buzz in web application architectures. It comes from event-driven desktop application design and doesn't fit into web application design very well. But luckily nobody really knows what MVC means, so we can call our presentation layer separation mechanism MVC and move on. (Rasmus Lerdorf)


  •  

    Posting Permissions

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