Loading
Ozgrid Excel Help & Best Practices Forums

Excel Video Tutorials / Excel Dashboards Reports



Results 1 to 3 of 3

Thread: Select Specific Slide From .pps Show

  1. #1
    Join Date
    14th December 2005
    Posts
    40

    Select Specific Slide From .pps Show

    Hello again,

    I am trying to use excel to open a specific slide on a specific .pps show.

    In my sheet, I have the network address of the .pps file in one cell and the number of the slide I want to show in another.

    This is what I've got..


    VB:
    Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean) 
        Const ERR_APP_NOTFOUND As Long = 429 
        On Error Resume Next 
         
        Dim X As String 
        Dim Y As String 
         
         
         
        If Intersect(Target, Range("STARTTIME")) Is Nothing Then 
        Else 
             
             ' X = Location of .pps
             'Y = Number of slide to start from
            X = Target.Offset(0, 5).Text 
            Y = Target.Offset(O, 8).Text 
             
            Set objApp = CreateObject("PowerPoint.Application") 
            If Err = ERR_APP_NOTFOUND Then 
                MsgBox "Power Point isn't installed on this computer. Could not automate PowerPoint." 
                Exit Sub 
            End If 
             
            With objApp 
                .Activate 
                .Presentations.Open Filename:=X, ReadOnly:=msoFalse 
                .ActivePresentation.Slides(Y).Select 
                 
                 
                 ' I tried this but didn't work either -->   ActiveWindow.View.GotoSlide Index:=Y
            End With 
            Set objApp = Nothing 
             
            Exit Sub 
        End If 
    
    
    The slideshow opens fine but does not go to the correct slide number.

    I can use this same code to open a .ppt file and it does go to the correct slide number. But not sure how to get it to start playing from this point without having to hit {shift} {F5}.


    Any ideas would be great.

    Thanks,

    Excel Video Tutorials / Excel Dashboards Reports


  2. #2
    Join Date
    2nd May 2007
    Posts
    30

    Re: Select Specific Slide From .pps Show

    Try
    ActivePresentation.SlideShowWindow.View.GotoSlide (Y)
    John Wilson
    PowerPoint MVP
    Free PowerPoint Tutorials

  3. #3
    Join Date
    14th December 2005
    Posts
    40

    Re: Select Specific Slide From .pps Show

    I tried your code in several different locations, but would not work with a .pps.

    I was able to use sendkeys to simulate a shift f5 command but that's not really what I was hoping to do.

    Any suggestions?

    Thanks,

    Excel Video Tutorials / Excel Dashboards Reports


Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Possible Answers

  1. Update Slide Show
    By hallglenanimal in forum Excel and/or Powerpoint Help
    Replies: 1
    Last Post: March 16th, 2007, 05:45
  2. Link Worksheet In PowerPoint Slide Show
    By damcdono in forum Excel and/or Powerpoint Help
    Replies: 4
    Last Post: February 23rd, 2005, 03:07
  3. Keyboard shot cut for slide show
    By Ralph in forum Excel and/or Powerpoint Help
    Replies: 2
    Last Post: October 30th, 2004, 22:09

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
porno