Out of memory error

  • Thread starter Francesco Guiseppe Linguine
  • Start date
F

Francesco Guiseppe Linguine

Why I get "out of memory" in vba code. I have a code to a clear range?

Thisworkbook.Worksheets("C1").Range("DataRange").ClearContents


It work a good until yesterday. I have to a reboot after run a my code.
 
D

David McRitchie

Francesco,
I presume that C1 is a worksheet that didn't exist prior to your
problems, I think you will have trouble if you name worksheets
with names that could be cell addresses or defined names.
 
F

Francesco Guiseppe Linguine

David McRitchie said:
Francesco,
I presume that C1 is a worksheet that didn't exist prior to your
problems, I think you will have trouble if you name worksheets
with names that could be cell addresses or defined names.

No, I rename sheet to a Company1 and still out of memory. I open old file
and macro work.
 
D

David McRitchie

You might check out some MS KB articles referenced in
Memory Leakage in GDI (graphics device interface) Resources (#GDI)
http://www.mvps.org/dmcritchie/excel/slowresp.htm#gdi

and root around in Charles Williams site
Also see Memory & Limits by Charles Williams. you will have to look at (frames at top) topics separately: Types of Memory,
Measuring Memory, Memory Limits, Memory Leaks. [good information, but best viewed with a Mozilla type browswer like Firefox].
http://www.decisionmodels.com/memlimitsc.htm
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top