+ Reply to Thread
Results 1 to 2 of 2

crash on VBA - only on some laptops, never on PC - no messages, just shut down excel!

  1. #1
    Registered User
    Join Date
    10-22-2017
    Location
    ENGLAND
    MS-Off Ver
    2016
    Posts
    35

    crash on VBA - only on some laptops, never on PC - no messages, just shut down excel!

    I have a workbook with VBA code, that works brilliant on four different PC's.
    But on two laptops, it shuts down excel without any warning messages, when executing a vba code.
    I have changed the vba code and fixed the issue, but then it crashes on another bit of code.
    but it never crashes on PC's or my own laptop. All excel 2016 windows 10.
    Is it to do with add-ons, or memory or processor speed?
    how can I fix this?

    many thanks for any suggestions.

  2. #2
    Registered User
    Join Date
    10-22-2017
    Location
    ENGLAND
    MS-Off Ver
    2016
    Posts
    35

    Re: crash on VBA - only on some laptops, never on PC - no messages, just shut down excel!

    Solved - I have found that when modifying any element of a chart, unless I actually selected the chart at least once initially, then on some PC's (and only some) it would crash and shut down excel.
    Even if the PCs all use windows 10 and excel 2016 - With no com add-ins.

    The problem code is as follows
    [code]
    Sub chart_run_OD()
    Dim runcht As Chart
    Set runcht = Sheets("run chart").ChartObjects("Chart_run").Chart
    runcht.ChartTitle.Text = "OD" 'this is the crash point on some PC's and not always - only around 1/5 times when the code is run!
    'extra code here
    end sub
    [code/]

    here is the code that fixed the problem
    [code]
    Sub chart_run_OD()
    Dim runcht As Chart
    Set runcht = Sheets("run chart").ChartObjects("Chart_run").Chart
    ActiveSheet.ChartObjects("Chart_run").Select
    runcht.ChartTitle.Text = "OD"
    'extra code here
    end sub
    Last edited by david killoran; 04-26-2019 at 02:12 PM.

+ 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] slicer crash excel only on some laptops
    By david killoran in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-26-2019, 02:15 PM
  2. Replies: 9
    Last Post: 01-09-2019, 12:33 PM
  3. [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
  4. Shut Down Excel
    By S.U.S.S. in forum Excel General
    Replies: 3
    Last Post: 11-01-2007, 11:28 AM
  5. Excel won't shut down
    By vak27 in forum Excel General
    Replies: 1
    Last Post: 05-24-2007, 01:45 PM
  6. Excel and Laptops
    By astrikor in forum Excel General
    Replies: 3
    Last Post: 02-12-2006, 07:29 PM
  7. [SOLVED] Shut down excel
    By Greg B in forum Excel General
    Replies: 1
    Last Post: 04-26-2005, 03:06 AM

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