This might sound stupid, but I was having the same problem before and after constantly trying to figure out what it was, I found that the power cable was barely in the socket, so that any little bump (door opening/shutting, people walking hard, etc.) would turn the computer off. Of course I've also had a fried who was having the same problem and his power supply had gone bad (and now he's borrowing my spare, grrrrr). You might want to check both of those.