Macros crash, "Not enough memory"

C

CLR

Hi All.........
I have an Excel file with a BUNCH of macros. The file basically takes a
downloaded database as an Excel file and imports it and massages it and
Autofilters sections of it out to 15 different sheets.......the external file
is about 1.5MB and the entire combined thing is a little over 3MB, so it's
not really huge. Problem is on this 864MB/512MBRAM machine here at work, the
program crashes near the end and gives Out of Memory error. The same file
runs fine on my 1.2GB/512MBRAM machine at home, and even on my 366MB/160MBRAM
laptop.

There is 1.7GB free on the HD of the problem machine, and nothing in the
TrashBin......no other programs running......only difference that I can see
is the problem machine is on the network at work. The home machine is on a
wireless LAN, and the laptop is independent. I get the same results on the
problem machine using XL97, 2000, and 2002.

Any ideas would be appreciated..........

Vaya con Dios,
Chuck, CABGx3
 
J

Jim Cone

Hi Chuck,
Emptying the Temp file is usually the first thing to try.
I am not sure what the other things might be. <g>
Start | Run | %temp%
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware


"CLR" <[email protected]>
wrote in message
Hi All.........
I have an Excel file with a BUNCH of macros. The file basically takes a
downloaded database as an Excel file and imports it and massages it and
Autofilters sections of it out to 15 different sheets.......the external file
is about 1.5MB and the entire combined thing is a little over 3MB, so it's
not really huge. Problem is on this 864MB/512MBRAM machine here at work, the
program crashes near the end and gives Out of Memory error. The same file
runs fine on my 1.2GB/512MBRAM machine at home, and even on my 366MB/160MBRAM
laptop.

There is 1.7GB free on the HD of the problem machine, and nothing in the
TrashBin......no other programs running......only difference that I can see
is the problem machine is on the network at work. The home machine is on a
wireless LAN, and the laptop is independent. I get the same results on the
problem machine using XL97, 2000, and 2002.

Any ideas would be appreciated..........

Vaya con Dios,
Chuck, CABGx3
 
C

CLR

Thanks Jim, but that didn't work.

It appears that the problem is OS related rather than Excel related. Memory
is definately NOT the problem, even tho that is the Error Report. The
program consists of about 18 major macros that each work fine individually,
but fail about number 16 each time when they are run in succession, either by
another macro, or by hand.

Two computers using WinMe work fine, and one has only 160MBRAM. Two
computers using Win2000 failed, and five computers using WinXP failed.

It appears that there is some sort of control in those OS's which decides
that the program had done enough operations and prevents any further
operation. I don't know if it's limited to "number of lines of code" or
"number of macros" or what......but I need to solve the problem because this
program does in two minutes what the users were taking 3 hours to do by hand
each week.

Any other ideas?

Vaya con Dios,
Chuck, CABGx3
 
C

CLR

To prove there was not a bad spot in the code, I took the two macros at the
end of the string where the program crashed, and moved them away up forward
so they would be processed early...........the program processed them just
fine, and still failed in XP when it got to the point where the old macros
were.....failing on the new macro that is now in that position.....The
problem is not the code.......the code runs fine in Me

Vaya con Dios,
Chuck, CABGx3
 
C

CLR

Follow-up note:
The Compatibility adjustment procedure worked fine in my case on Excel 97
and on Excel 2002 for running my program on a WinXP machine. HOWEVER, it
would NOT work on Excel 2000-SP3. In fact, it disabled Excel 2000-SP3 so it
would not even work at all.......this on 2 different WinXP machines..just a
heads-up for anyone trying the Compatibility adjustment.

Vaya con Dios,
Chuck, CABGx3
 

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