Another possibility for a temporary soluction, until you make the hardware changes suggested by dlwolff and Ray:
If it happens when your machine's been on for a while, it's probably a memory leak. In other words, a program is using memory and not returning it when it should. This is very common. For example, I often get that message if I leave a document open too long in Foxit Reader 3.0.
The temporary solution is to pay attention to which programs are doing it, and to close them immediately when you're finished with them. Don't leave them open out of habit or laziness.