Hi, Lina.
It depends upon whether it's a PPS file or PPT file, but to automatically
run the presentation in full screen mode, try:
Public Sub runPowerPoint()
On Error GoTo ErrHandler
Dim ppApp As Object
Dim ppPres As Object
Set ppApp = CreateObject("PowerPoint.Application")
ppApp.Visible = True
'-----------------------------------------
' Use the following for PPS files:
'-----------------------------------------
Set ppPres = ppApp.Presentations.Open("C:\PPT\MyShow.pps")
'-----------------------------------------
' Or use the following for PPT files:
'-----------------------------------------
'Set ppPres = ppApp.Presentations.Open("C:\PPT\MyShow.ppt")
'ppPres.SlideShowSettings.Run
CleanUp:
Set ppPres = Nothing
Set ppApp = Nothing
Exit Sub
ErrHandler:
MsgBox "Error in runPowerPoint( )." & vbCrLf & vbCrLf & _
"Error #" & Err.Number & vbCrLf & vbCrLf & Err.Description
Err.Clear
GoTo CleanUp
End Sub
This works for PPS files, but if you want to use PPT files, then comment out
the PPS files section and uncomment the PPT files section, save and compile.
HTH.
Gunny
See
http://www.QBuilt.com for all your database needs.
See
http://www.Access.QBuilt.com for Microsoft Access tips and tutorials.
http://www.Access.QBuilt.com/html/expert_contributors2.html for contact info.
- - -
If my answer has helped you, please sign in and answer yes to the question
"Did this post answer your question?" at the bottom of the message, which
adds your question and the answers to the database of answers. Remember that
questions answered the quickest are often from those who have a history of
rewarding the contributors who have taken the time to answer questions
correctly.