Are you sure it isn't the charger?
Try turning off the laptop (off not sleep or hibernate) and see if it will charge when off. If it will actually charge when turned off, then the charger is starting to go bad and would need replacing.
However, if it will not charge even when off, then it could be the battery (especially if the new one is an aftermarket one) or the charging circuit.