Consulting

Results 1 to 7 of 7

Thread: Solved: Excel Freezing When Macro Runs

  1. #1

    Solved: Excel Freezing When Macro Runs

    Hi,

    I was just wondering if anyone knows why excel freezes when a macro is run?

    1) i have V.1 and V.2
    V.1 has no background colour
    V.2 has background colour

    it says calculating in the bottom right and then just freezes.


    Thank you for your time


    Nurofen

  2. #2
    Moderator VBAX Wizard Aussiebear's Avatar
    Joined
    Dec 2005
    Location
    Queensland
    Posts
    5,060
    Location
    And just what is the code in the macro?
    Remember To Do the Following....
    Use [Code].... [/Code] tags when posting code to the thread.
    Mark your thread as Solved if satisfied by using the Thread Tools options.
    If posting the same issue to another forum please show the link

  3. #3
    http://vbaexpress.com/forum/showthre...t=15913&page=2

    post #28

    works fine

    but i've now coloured the sheets and it freezes

  4. #4
    Funny but i just tested:

    If I use countif =countif(A1:A10000,"cats") no problem V.1
    If I use countif =countif($A$:$A$10000"b2") it freezes V.2

    does anyone know why?

    Thank you for your time

    Nurofen

  5. #5
    VBAX Master XLGibbs's Avatar
    Joined
    Jan 2006
    Location
    state of confusion, but vacation in denial
    Posts
    1,315
    Location
    I am assuming your second fomula actually has a , before the "b2"

    =countif($A$1:$A$10000,B2) would be the correct way

    Perhaps not using countif, or reducing the range (do you need to count 10,000 rows?)
    If you have posted the same question at multiple forums, please read this IMPORTANT INFO.

    Please use the thread tools to mark your thread Solved


    Please review the Knowledge Base
    for samples and solutions , or to submit your own!




  6. #6
    VBAX Master XLGibbs's Avatar
    Joined
    Jan 2006
    Location
    state of confusion, but vacation in denial
    Posts
    1,315
    Location
    Also, it isn't really "frozen" or dead, it is just that the CPU is too occupied with a hog of a formula (or an incorrect one that is having unintended consequences) to update the screen.

    I have had the white screen of apparent death a number of times, but sometimes waiting it out will work.
    If you have posted the same question at multiple forums, please read this IMPORTANT INFO.

    Please use the thread tools to mark your thread Solved


    Please review the Knowledge Base
    for samples and solutions , or to submit your own!




  7. #7
    hI XLGibbs,

    If I use countif =countif($A$:$A$10000"b2") it freezes V.2
    ya typing too fast= If I use countif =countif($A$:$A$10000,"b2")

    I have reduced the range works ok now.

    Thanks mate

    Thanking you for your time

    Nurofen

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •