Should work in 2007. It sounds like whatever you are doing in not running the macro at all.
If you insert this MsgBox "OK,I'm running"
Like this:
Sub newshow()
Dim nextpres As Presentation
Msgbox "OK,I'm running"
SlideShowWindows(1).Parent.Windows(1).WindowState = ppWindowMinimized
SlideShowWindows(1).View.Exit
Set nextpres = Presentations.Open("C:\Users\John\Desktop\bug.pptx ")
nextpres.Windows(1).WindowState = ppWindowMinimized
nextpres.SlideShowSettings.Run
End Sub
If you don't see the message then the button is not running the code and you need to investigate why.
|