Power supply, motherboard. Check motherboard for broken capacitors (they will not be flat but bulging with maybe even some dark stuff coming out of them). Try a new power supply if the motherboard looks good.
just put a new power supply in a month ago, thanks, didint see any capacitors that looked like that, but I will check again
Could still be the power supply, although with the info you got a new one recently it's less likely. Maybe RAM or CPU, but that tends to get further in the boot process and will beep at you instead of just starting and shutting down.
do you think it would be worth putting anoher mother board in? I have read a few reviews that say the motherboards aren't reliable any way. Thanks for your help
I would not say that motherboards are not reliable, depends on the brand and model. I have worked on old P4 systems that have run for 10 years and also some dual core systems that barely lasted 3 due to motherboard issues.
The only thing is that it "may" be the motherboard, but there is really no way to find out without replacing it. So you're a bit stuck there unless you have a spare around. Will need to spend money to find the issue.