Try this:
Right-click on My Computer, go to Properties, on the
System Properties window go to the Advanced tab, and in
the Startup and Recovery area, click on the Settings
button. Once in, turn OFF (uncheck) Automatically
Restart. It's under System Failure. OK your way out.
The next time the problem occurs you will at least get a
blue screen which may provide a clue about the problem.
Before doing this you may want to go to the Event Viewer
and look for a clue there. Right-click on My Computer, go
to Manage and look through the logs for System,
Application, Security (in that order).
Good Luck !