Trevor,
To check if a presentation is already open you need to iterate thru the
presentation collection.
' ---------------------------------------------------------------------------------------
Function IsPresentationOpen(Filename As String) As Integer
Dim Index As Integer
For Index = 1 To Presentations.Count
If LCase(Presentations(Index).FullName) = LCase(Filename) Then
'Return the Index of the presentation if open
IsPresentationOpen = Index
Exit Function
End If
Next Index
IsPresentationOpen = 0
End Function
Usage:
Sub Test()
If IsPresentationOpen("E:\Docs\individual notes potrait.ppt")>0 then
MsgBox "Presentation is open"
Else
Msgbox "Presentation is not open"
End If
End Sub
'----------------------------------------------------------------------------------------
--
Regards,
Shyam Pillai
Animation Carbon:
http://skp.mvps.org/ac/