Please do try these troubleshooting steps that I just suggested to others who had the same problem.
- Start by doing a test with the AC adapter and battery.
- First, remove the battery and boot it up with just the AC adapter connected and see if it would stay on.
- If the laptop will boot up normally with just the AC adapter then means the problem is with the battery.
- But if it will still shut down you'll need to try a different AC adapter that has the same voltage to make sure that it's not the AC adapter that is faulty.
- Lastly, try to reinstall Windows and see if the same problem will persist or not.
- If a different AC adapter will also not work that means the problem is the motherboard and if your laptop is still under the factory warranty do send it for a repair.