Some other things to try...
Open computer case, and clean any dust build up from CPU, and CPU fan.
If you have video card with a fan, do the same maintenance for it.
Leave the case open for better cooling, run your computer, and see if same thing happens.
When your problem happens, are you running some other applications, like games?
You may try replacing CPU fan (it's cheap).
How old is your machine?