+ Reply to Thread
Results 1 to 3 of 3

I know this may be a crazy question but....

  1. #1
    CLamar
    Guest

    I know this may be a crazy question but....

    I have code where i have to activate the sheet in order for the code
    correctly. Now, I dont want that sheet to be displayed because it slows down
    the macro. Is there a way to either Activate the sheet and not have it
    displayed or another way to disable screen updating besides
    Application.ScreenUpdating = False cause that doesnt work

    thanks

  2. #2
    Dave Peterson
    Guest

    Re: I know this may be a crazy question but....

    There are very few things that depend on the activesheet.

    I think I'd try to rewrite the code that depends on the activesheet.

    And I've never seen .screenupdating fail. I have seen it turn on when I used
    something out of the Analysis toolpak (IIRC). But since I can't control that,
    I'll just add another .screenupdating = false to freeze it when the ATP call
    finishes.



    CLamar wrote:
    >
    > I have code where i have to activate the sheet in order for the code
    > correctly. Now, I dont want that sheet to be displayed because it slows down
    > the macro. Is there a way to either Activate the sheet and not have it
    > displayed or another way to disable screen updating besides
    > Application.ScreenUpdating = False cause that doesnt work
    >
    > thanks


    --

    Dave Peterson

  3. #3
    CLamar
    Guest

    Re: I know this may be a crazy question but....

    Do you have any suggestions for not having the sheet active in order to
    proceed with the code. When I dont make the sheet active it gives me the
    error "Method 'Range' of object Global failed". Here is an example of the
    code:
    The error occurs at the line beginning with newfbr when i comment out the
    Sheets("Plotdata").Activate line

    Do Until oldfbr > LastCellVRH1x
    Sheets("AreaSolver").Range(PS.Cells(8, 1), PS.Cells(36, 6)).Clear
    'Sheets("PlotData").Activate
    With Sheets("PlotData")
    top = oldfbr
    newfbr = Range("F" & oldfbr & "").End(xlDown).Row
    bottom = newfbr
    oldfbr = newfbr + 3
    SerialName = Sheets("Sheet4").Range("E" & i & "").Value
    ChartTitle = Sheets("Sheet4").Range("C" & i & "").Value
    TestMethod = Sheets("TestTable").Range("I" & i + 1 & "").Value
    AreaLabel = Sheets("Sheet4").Range("E" & i & "").Value & " / " & _
    Sheets("Sheet4").Range("D" & i & "").Value

    "Dave Peterson" wrote:

    > There are very few things that depend on the activesheet.
    >
    > I think I'd try to rewrite the code that depends on the activesheet.
    >
    > And I've never seen .screenupdating fail. I have seen it turn on when I used
    > something out of the Analysis toolpak (IIRC). But since I can't control that,
    > I'll just add another .screenupdating = false to freeze it when the ATP call
    > finishes.
    >
    >
    >
    > CLamar wrote:
    > >
    > > I have code where i have to activate the sheet in order for the code
    > > correctly. Now, I dont want that sheet to be displayed because it slows down
    > > the macro. Is there a way to either Activate the sheet and not have it
    > > displayed or another way to disable screen updating besides
    > > Application.ScreenUpdating = False cause that doesnt work
    > >
    > > thanks

    >
    > --
    >
    > Dave Peterson
    >


+ 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