Consulting

Results 1 to 9 of 9

Thread: Actions - Run Program (Path Problem)

  1. #1

    Actions - Run Program (Path Problem)

    Hi - I want to run a camtasia .exe file between slides. I've added a text box which when clicked lauches the file using the run program option of the action settings. Trouble is this will be on CD and the CD drive letter could change. Does anyone know how I can alter the path so that it runs from the CD no matter what the CD rom is mapped as?

    Also, is it possible to automaticly run the .exe between slides without having to click on the specific text box? As I want to publish this as a show I'm guessing that macro's won't work??

    Cheers,
    rrenis

  2. #2
    VBAX Sage
    Joined
    Apr 2007
    Location
    United States
    Posts
    8,729
    Location
    You could "brute force" your way from D: to Z: looking to see if the program exe exists (FileExists Method and the DriveExists Method) and when you find it, run it

    Paul

  3. #3
    Thanks Paul - hadn't thought of that!

    Just one last thing - does anyone know how to trigger VBA after a click event moves to the next slide? I'd like to run a file between slides? I'm sure it's probably straight forward but until now I've not really touched powerpoint!

    Cheers,
    rrenis

  4. #4
    Just had a thought - I could get the directory of the CD/DVD-Rom drive from the following (then just use LEFT to grab the first letter, i.e. the drive).

    ActivePresentation.FullName
    Any help on triggering events at the end of a slide would be great

    EDIT: Macros don't seem to work when it's a .pps file. So not able to use macro's after all (I'll make do with the actions settings)

    Cheers,
    rrenis
    Last edited by Aussiebear; 04-28-2023 at 02:26 AM. Reason: Adjusted the code tags

  5. #5
    VBAX Master
    Joined
    Feb 2007
    Posts
    2,094
    Location
    sorry double post!
    John Wilson
    Microsoft PowerPoint MVP
    Amazing Free PowerPoint Tutorials
    http://www.pptalchemy.co.uk/powerpoi...tutorials.html

  6. #6
    VBAX Master
    Joined
    Feb 2007
    Posts
    2,094
    Location
    The "real" way to make macros run in response to click events is to write an event handler which would involve class modules. If this means nothing to you then this "bodge" may help:
    http://www.pptalchemy.co.uk/autovba.html

    BTW Macros DO run in .pps files, you might mean they won't run in the free viewer
    John Wilson
    Microsoft PowerPoint MVP
    Amazing Free PowerPoint Tutorials
    http://www.pptalchemy.co.uk/powerpoi...tutorials.html

  7. #7
    VBAX Sage
    Joined
    Apr 2007
    Location
    United States
    Posts
    8,729
    Location
    John --

    "bodge" ??? Is that the same as a "kludge" on my side of the pond?

    Also, could / would you post the Class code for PP, or point me to a writeup as to where the app events are described?

    Thanks

    Paul

  8. #8
    VBAX Master
    Joined
    Feb 2007
    Posts
    2,094
    Location
    John Wilson
    Microsoft PowerPoint MVP
    Amazing Free PowerPoint Tutorials
    http://www.pptalchemy.co.uk/powerpoi...tutorials.html

  9. #9
    Thanks John!!

    Cheers,
    rrenis

Posting Permissions

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