If your program uses a lot of windows resources it could be a Resource Heap shortage.
There is a registry entry that can be increased to raise the heap size for XP. For Vista Microsoft already sets the default value higher. I recommend changing the default 3072 to at least 8192.
I suggest you read the knowledgebase article but the basic info on the change is:
- Run Registry Editor (REGEDT32.EXE).
- From the HKEY_ LOCAL_MACHINE subtree, go to the following key:
- On the right hand side of the screen double-click on the key:
- On the pop-up window you will see a very long field selected. Move the cursor near the beginning of the string looking for this (values may vary):
- SharedSection specifies the System and desktop heaps using the following format:
xxxxdefines the maximum size of the system-wide heap (in kilobytes),
yyyydefines the size of the per desktop heap, and
zzzdefines the size of the desktop heap for a “non-interactive” window station.
- Change ONLY the
yyyyvalue to 8192 (or larger) and press OK.
- Exit the Registry Editor and reboot the PC for the change to take effect.