+ Reply to Thread
Results 1 to 3 of 3

Scrolling Issue After Code/Macro

  1. #1
    Registered User
    Join Date
    07-31-2012
    Location
    Midwest
    MS-Off Ver
    Excel 2007
    Posts
    31

    Scrolling Issue After Code/Macro

    Hello,

    I've tried my best to search, but cannot find anything concrete.

    I'm using Excel 2013 and I've programmed some automation into Visual Basic. It's fairly simple stuff, such as copying and pasting data from one sheet to another, etc.

    Unfortunately, what is happening is after the macro runs, the worksheet I end up on (the data has pasted just fine), but when using the scroll button on my mouse or the arrows on my keyboard, the worksheet itself does not respond. I can see the scroll bar at the right going up and down as I either use the scroll button on the mouse or the arrow keys, but again, the worksheet does not respond. This is not a freeze panes issue, the destination worksheet does not have frozen panes.

    In the little bit I was able to find on the internet from folks with similar issues is that it appears as though (through my own testing as well) the original worksheet (where the data was copied from), that worksheet is actually the one that is being scrolled through. So, it's very strange, but the scrolling ability seems to not come along after the code has completed what it's supposed to do.

    Another thing, I have removed all of the Application.ScreenUpdating True/False as I thought maybe I was forgetting to put it back once I took it off. So I completely took all of any code based screen updating out.

    Another key piece of information. If I am to go to another worksheet in the workbook and then BACK to where the data was copied to (where the code ended), I am then able to scroll again.... and everything works like it should. However if I program the worksheet changes to happen, so from the destination sheet to another sheet and then back to the destination sheet, it still does not work.

    I'm at a loss. I hope there is someone out there who has had the same problem and has been able to find a solution.

    Thanks in advance for anyone who is able to point me in the right direction.

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,496

    Re: Scrolling Issue After Code/Macro

    Another key piece of information
    ... would be the code, ideally sitting in a sample workbook


    Regards, TMS
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Registered User
    Join Date
    07-31-2012
    Location
    Midwest
    MS-Off Ver
    Excel 2007
    Posts
    31

    Re: Scrolling Issue After Code/Macro

    Hello,

    Some follow-up on my original problem.

    My code is run from a Button (Form Control) on one sheet, and I have a feeling after the code runs, even though the sheet with the button isn't visible or activated, somehow Excel in the background ends up thinking it's still on that sheet.

    I say this because if I run the macro without the button, then everything runs fine and I am able to scroll like normal. So it has to be something strange with the Form Control button.

    Does anyone have any ideas?

+ 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] Macro code Issue!
    By Chrispylcfc in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-06-2013, 03:29 PM
  2. [SOLVED] I can manually (F8) step through my code with no issue, run the macro and fail, why?
    By galvinpaddy in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 01-17-2013, 07:13 AM
  3. scrolling issue
    By honsbeek in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-14-2007, 06:27 AM
  4. Macro Code issue
    By punter in forum Excel General
    Replies: 3
    Last Post: 03-15-2007, 06:05 PM
  5. Scrolling Issue
    By cob943 in forum Excel General
    Replies: 5
    Last Post: 11-08-2006, 05:23 PM

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