RedSector73 wrote:
Q code only matters if gets stuck on them. Is that what you are saying ?
How long was power out and how old is the motherboard approx ?
edit: On re-reading your post;
Just replace the BIOS battery with a brand new name-brand battery first and see if anything changes. CR2032 is the battery.
I suspect this is the cause of all your issues - dead/dying BIOS battery.
The power was out for about 10 minutes. All the components I bought in 2017, except for the psu. I had a blown psu and replaced it couple of months ago. Right after the power out I was able to boot to my desktop but dealing with the restarts and freezes as I mentioned in my post. The date and time was set to the year 2080. Every time I corrected it, it reverts back to the year 2080 after the restarts. So my first thought was changing the cmos battery and I did. I was able to fix the date and time issue but still had the restart and freezing loop problem.
I followed an advice on the internet to do a clean boot and I disabled all services (including Microsoft) on msconfig. This stopped the restart loop and I think this was the time I did the memtest86 and chkdsk. I would enable one service by another followed by a manual restart trying to figure out what causes the restart loop by process of elimination. As I was doing so, the PC suddenly would'nt boot at all. The fans and the lights would be on but nothing shows on screen and the q code would be stuck on either 04, 18, 19 or 25. I tried rotating and removing the ram sticks but nothing works.