First off, have you updated any files, drivers, programs? Have you installed any new programs? Look for the problem there first.
If you are using Win98, WinME, or WinXP, go to Start/Run and type msconfig in the open box. Then click ok. That will take you to the System Comfiguration Utility. Click on the General tab.
Click on the Selective Startup circle, then UNCHECK the Load Startup Items box. (This will shut off all the junk that starts up everytime you boot the computer.) Then click on the Apply and OK buttons at the bottom right of the box. Let the computer reboot.
See if that cures the problem. If it does go back to msconfig and click on the Startup tab. Then put a check mark in one of the boxes and click apply and ok and reboot. Do this until you check an item and it causes the problem. Then that will be the item that's giving you the problem. Get rid of the item or reinstall it, etc. Be aware that it may be a combination of items. It takes some time to troubleshoot. But it might locate the problem area.
If you unchecked the Load Startup Items and rebooted and still have the problem then this is not the problem area.
Reboot and press the F8 key about once a second as the machine is rebooting until you get the safe mode menu. Then go to safe mode. Does the problem happen in safe mode? If it does then you are probably looking at either a hardware or Windows problem. May need to reload Windows.
If the problem went away then it may be a software problem or a hardware driver problem. Safe mode uses generic drivers so eliminates driver issues (usually). Then you are down to figuring out what driver is giving you a problem. It will usually be either video or printer driver.
Be sure to go back to msconfig and put the check mark back in the Load Startup Items checkbox, then click on the Normal Startup circle, and then do apply and ok and reboot. But make sure you remove any program that was causing a problem before you do this.
Hope this helps.
Diamondback