+ Reply to Thread
Results 1 to 7 of 7

Excel VBA / Powerpoint crash problem

  1. #1
    Registered User
    Join Date
    11-02-2016
    Location
    Cornwall, England
    MS-Off Ver
    Mac - 2016
    Posts
    11

    Excel VBA / Powerpoint crash problem

    Hello,

    I'm struggling with a strange problem. I'm writing some Excel VBA to perform some analysis on a large batch of PowerPoint presentations that I'm working on. I ultimately want to generate a worksheet for each presentation with some stats on it - number of slides, number of shapes on each slide etc.

    The issue I'm having, however, is much more fundamental - it keeps crashing for some reason, and it's always when I'm making use of slide objects. For example:
    Please Login or Register  to view this content.
    That last line will trigger a crash, every time. It doesn't matter what I actually refer to - I've just used slide 8 as an example here. Any use of ppSlide, or any attempt to refer to a specific slide in the presentation, will crash Excel.

    I'm using Mac OS X High Sierra 10.13.6, and Excel 16.16.1

    All help gratefully appreciated!
    Last edited by Big_Benjamin; 09-02-2018 at 03:34 PM.

  2. #2
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Excel VBA / Powerpoint crash problem

    What happens if you try a debug.print of:

    ppPres.slides.count ?

    Do you really have 8 slides in your presentation?

    I also see in the Power Point object model there is a "Slide" object as well as a "Slides" object
    https://docs.microsoft.com/en-us/off...t/object-model

    Perhaps you have an illegal dim where you are trying to use one of those reserved words as a variable?
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  3. #3
    Registered User
    Join Date
    11-02-2016
    Location
    Cornwall, England
    MS-Off Ver
    Mac - 2016
    Posts
    11

    Re: Excel VBA / Powerpoint crash problem

    Thanks for the reply.

    I just used slide number 8 as an example - I've got lots of different presentations, and they all have between 20 and 50 slides. It doesn't really matter what specific code I use - any attempt to address a specific slide results in a crash. I don't think its anything to do with using "ppSlide" as a variable name - lots of people do that, and I've used it before. I've also tried changing it just to be absolutely sure. I also tried not setting or using ppSlide at all, and just using longer hand references such as ppPres.slides(x) whenever I want to do something, but that crashes as well.

    Very frustrating!

  4. #4
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Excel VBA / Powerpoint crash problem

    Have you had success on the Mac as well as the PC platform?

    In my experience a crash is very rare and many times I'm trying to use a word that is reserved and should not be used as I'm trying to use it.

    If you can display the "Object Browser" for PowerPoint, you can see all the Object names and most of them are reserved. Perhaps you can find the one that is killing your code.

  5. #5
    Registered User
    Join Date
    11-02-2016
    Location
    Cornwall, England
    MS-Off Ver
    Mac - 2016
    Posts
    11

    Re: Excel VBA / Powerpoint crash problem

    I've only got access to Mac - I strongly suspect it is a Mac only issue, as Excel VBA seems to be a bit flaky on Mac, and I've never had an issue when I've used PCs in the past.

    I don't think it's a reserved name issue - I've tinkered around with lots of different permutations and nothing changes the problem.

  6. #6
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Excel VBA / Powerpoint crash problem

    Hi Big B,

    I only know the PC and don't have a Mac. Maybe one of the Mac Excel Guru's will have an idea on this one.

  7. #7
    Registered User
    Join Date
    11-02-2016
    Location
    Cornwall, England
    MS-Off Ver
    Mac - 2016
    Posts
    11

    Re: Excel VBA / Powerpoint crash problem

    Thanks. I hope so!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Excel 2007 crash: Just open the file, do anything to it, save, close, open againg = CRASH
    By Alex Piotto in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 03-27-2018, 07:53 AM
  2. Problem copying PivotChart from Excel to PowerPoint
    By quinnj09 in forum Excel General
    Replies: 1
    Last Post: 07-20-2017, 07:04 AM
  3. Problem with pasted Excel object in PowerPoint
    By Bjordion in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-14-2013, 04:05 PM
  4. Problem launching powerpoint from excel
    By rut in forum Excel General
    Replies: 0
    Last Post: 05-12-2008, 03:18 PM
  5. Excel macros to PowerPoint problem
    By tyler3 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-13-2006, 04:44 PM
  6. Replies: 2
    Last Post: 09-12-2006, 10:33 AM
  7. [SOLVED] Path\File name length problem Excel Crash on save as
    By Datasort in forum Excel General
    Replies: 0
    Last Post: 04-08-2005, 01:06 PM

Tags for this Thread

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1