Article ID: 165218
Article Last Modified on 10/11/2006
Sub DeleteCustomShow()
'Change this string to the name of the custom show you want to
'delete.
Const strShowToDelete As String = "My Custom Show"
Dim oShow As NamedSlideShow
Dim strPrompt As String
Dim FoundShow As Boolean: FoundShow = False
'Loop though the custom shows in the active presentation.
For Each oShow In ActivePresentation.SlideShowSettings.NamedSlideShows
'Look for the custom show name defined by the constant
'strShowToDelete.
If oShow.Name = strShowToDelete Then
oShow.Delete
FoundShow = True
Exit For
End If
Next oShow
'Check if a show was deleted and then display a message box.
strPrompt = "The custom show " & strShowToDelete & " "
If FoundShow Then
MsgBox strPrompt & "was deleted.", vbInformation, _
"Custom Show Deleted"
Else
MsgBox strPrompt & "was not found.", vbInformation, _
"No Show Deleted"
End If
End Sub
176476 OFF: Office Assistant Not Answering Visual Basic Questions
163435 VBA: Programming Resources for Visual Basic for Applications
Additional query words: 8.00 ppt8 vba vbe 8.0 macppt98 ppt98 mac
Keywords: kbcode kbdtacode kbhowto kbmacro kbprogramming KB165218