Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
URGENT - Visual Basic Out of Memory
Hi All!
I have developed an application of approx 3.5mb.Quite a lot of VBA code and a lot of graphics, mainly forms that need to be completted by the user. Lately I have been unable to work on the prog as after a few minutes work i keep getting a message ... "Microsoft Visual basic - Out of memory". Excel has to be closed down. Impossible to load a second workbook. This problem has been acquired lately. The wkb has not altered substantially in size for many months. When Excel is loaded system rsources meter shows approx 64% available. Once XL application loaded system resources goes down to 9% available. I increased the memory from the original 128 mb to 256 mb still the same problem. I use an IBM ThinkPad 600x with 256mb memory using Windows 98 and Excel 2000. Thanks in adavnce |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
URGENT - Visual Basic Out of Memory
Use the Windows System Monitor application to see how much "Free Memory" you
have. Find it in Programs/Accessories, or if not loaded you may have to load it from the CD. It is "sysmon.exe" in the Windows folder. If Free Memory is below a couple MB you probably have a memory problem. 256MB should be enough unless your graphics files are huge. But Win98 can leak memory badly. You can watch System Monitor while your application runs to see how Free Memory is being used. You might want to consider moving up to an NT based OS like Win2K or WinXP which are much better about managing memory. HTH, Shockley "sgl" wrote in message ... Hi All! I have developed an application of approx 3.5mb.Quite a lot of VBA code and a lot of graphics, mainly forms that need to be completted by the user. Lately I have been unable to work on the prog as after a few minutes work i keep getting a message ... "Microsoft Visual basic - Out of memory". Excel has to be closed down. Impossible to load a second workbook. This problem has been acquired lately. The wkb has not altered substantially in size for many months. When Excel is loaded system rsources meter shows approx 64% available. Once XL application loaded system resources goes down to 9% available. I increased the memory from the original 128 mb to 256 mb still the same problem. I use an IBM ThinkPad 600x with 256mb memory using Windows 98 and Excel 2000. Thanks in adavnce |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
URGENT - Visual Basic Out of Memory
The only possibility I can think of is object cleanup. If
you declare any object variable (i.e. variant, workbook, range,) each one takes a fair chunk of memory. When it is no longer needed, do the following: Set Variable = Nothing That frees up a little memory. If you have enough of those, it could certainly add up. This may also be related to the graphics, which can eat up a ton of memory. I don't have any other ideas there except maybe to reduce the resolution or number of colors where you can. Good luck with that, Phil -----Original Message----- Hi All! I have developed an application of approx 3.5mb.Quite a lot of VBA code and a lot of graphics, mainly forms that need to be completted by the user. Lately I have been unable to work on the prog as after a few minutes work i keep getting a message ... "Microsoft Visual basic - Out of memory". Excel has to be closed down. Impossible to load a second workbook. This problem has been acquired lately. The wkb has not altered substantially in size for many months. When Excel is loaded system rsources meter shows approx 64% available. Once XL application loaded system resources goes down to 9% available. I increased the memory from the original 128 mb to 256 mb still the same problem. I use an IBM ThinkPad 600x with 256mb memory using Windows 98 and Excel 2000. Thanks in adavnce |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
URGENT - Visual Basic Out of Memory
Hi sgl,
You may want to try Rob Bovey's VBA Code Cleaner: http://www.appspro.com/utilities/Cleaner.asp Not sure if it'll help, but it's worth a try. 256MB RAM is still not very much, so if you're running into problems, you may want to consider going to 512. -- Regards, Jake Marx MS MVP - Excel sgl wrote: Hi All! I have developed an application of approx 3.5mb.Quite a lot of VBA code and a lot of graphics, mainly forms that need to be completted by the user. Lately I have been unable to work on the prog as after a few minutes work i keep getting a message ... "Microsoft Visual basic - Out of memory". Excel has to be closed down. Impossible to load a second workbook. This problem has been acquired lately. The wkb has not altered substantially in size for many months. When Excel is loaded system rsources meter shows approx 64% available. Once XL application loaded system resources goes down to 9% available. I increased the memory from the original 128 mb to 256 mb still the same problem. I use an IBM ThinkPad 600x with 256mb memory using Windows 98 and Excel 2000. Thanks in adavnce |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Visual Basic | Excel Discussion (Misc queries) | |||
Is Visual Basic the same as Visual Studio 2008? | Excel Worksheet Functions | |||
changing the visual basic in office 2003 to visual studio net | Excel Discussion (Misc queries) | |||
Visual Basic Code Remains in "memory" | Excel Worksheet Functions |