+ Reply to Thread
Results 1 to 8 of 8

Programatically Scrolling Whilst Populating Spreadsheet Without Crashing

  1. #1
    Registered User
    Join Date
    11-13-2009
    Location
    Cumbria
    MS-Off Ver
    Excel 2016
    Posts
    87

    Programatically Scrolling Whilst Populating Spreadsheet Without Crashing

    Hi Everyone,

    I've made an Excel VBA application that populates a 14 column, 2000 row table with data row by row. When it starts populating a new row, it uses application.Goto to select the row that's being populated. I really like this idea because it stops the user getting bored waiting for it to finish, as they can at least see how much progress is being made!

    Unfortunately, Excel crashes after 160 rows have been populated every time, and continues populating the sheet without scrolling.

    I know this might sound like a silly request, but if anyone can give me any tips on how to programmatically scroll whilst populating a spreadsheet without crashing, it would be much appreciated.

    Regards,

    Rowan
    Last edited by RowanB; 01-24-2013 at 09:46 AM.

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643
    Rowan

    How are you populating the rows?

    Does it really take that long that users will become bored waiting?
    If posting code please use code tags, see here.

  3. #3
    Registered User
    Join Date
    11-13-2009
    Location
    Cumbria
    MS-Off Ver
    Excel 2016
    Posts
    87

    Re: Programatically Scrolling Whilst Populating Spreadsheet Without Crashing

    I'm using visual basic to do some fairly time-consuming calculations on each row. The whole sheet can take around 5 minutes to populate. It's just a nice touch if the user can see how much progress is being made.

  4. #4
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Programatically Scrolling Whilst Populating Spreadsheet Without Crashing

    Rowan

    Scrolling down row by row could be slowing down your code.

    How about using something simple like the status bar to indicate progress?

    Not exactly exciting I know, but it might work.

    You could also look into using a userform with a progress bar, but that could also slow things down.

    PS How is Excel 'crashing'?

  5. #5
    Registered User
    Join Date
    11-13-2009
    Location
    Cumbria
    MS-Off Ver
    Excel 2016
    Posts
    87

    Re: Programatically Scrolling Whilst Populating Spreadsheet Without Crashing

    Yeah, I know it's slowing it down! haha Thanks for the status bar suggestion, It just says "not responding".

  6. #6
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Programatically Scrolling Whilst Populating Spreadsheet Without Crashing

    So how did you use the suggestion?

    Did you add code to set the text in the status bar?
    Please Login or Register  to view this content.
    You can reset the status bar like this.
    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    11-13-2009
    Location
    Cumbria
    MS-Off Ver
    Excel 2016
    Posts
    87

    Re: Programatically Scrolling Whilst Populating Spreadsheet Without Crashing

    Ah, that's a really cool idea Norie. Thank youy very much. I'll use that. I haven't tried a status bar yet.

  8. #8
    Registered User
    Join Date
    11-13-2009
    Location
    Cumbria
    MS-Off Ver
    Excel 2016
    Posts
    87

    Re: Programatically Scrolling Whilst Populating Spreadsheet Without Crashing

    I've just found out that I get exactly the same problem using the status bar. Excel says "not responding" after processing 77 rows and the status bar stops.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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