Is it charging even if the computer is turned off?
If not, this has nothing to do with Windows or Microsoft as it cannot be fixed as a software issue.
It can be the battery itself, charging port, or charging cable, or internal connection. You need to contact HP support or take it to a local repair place for thorough exam.