I would like to ask you for help regarding VBA and PowerPoint. I use Microsoft PowerPoint Object Library 16, which is probably the newest one.
I have an active PowerPoint presentation that I dynamically create during the presentation based on data in Access. I add more slides, add more texts with effects and more sound files to the slides. The entire animation is set to automatic, which means I don’t click anything and subsequent effects and music playback are triggered one after the other, everything works exactly as I want.
And here I have 2 questions:
- How to read the currently playing music file using VBA? (there are usually 3 or 4 music files on the slide, played in the appropriate order) I mean the title of the file that is currently being played. And possibly (not necessarily) how many minutes and seconds the playback has been going on, i.e. its progress.
- Is it possible to obtain an image of the currently playing slide, the content of which will correspond to a given moment of animation. I know there is an Export method, but it generates a slide image from editing mode and does not take into account the current state of the shapes on the slide at the time of calling.
As an additional curiosity, I wanted to ask if anyone has noticed that if slides are dynamically added and modified during the show (I mean the next slide, not the one being played), PowerPoint has problems with transitions and animations. It loses animations, the image flashes and similar unwanted effects, and if I stop the presentation and restart it, everything works as it should without any changes!
How to get the file name of the currently playing music embedded in a slide.
I’m searching object descriptions, trying to find a property corresponding to a boolean flag that would show that a given shape is currently being played as an animation, or a property showing the index of an object type shape that is being anomized, but I’m stuck with no effect.
Hypno is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.