Are you trying to charge it while turned on? If so, try charging it while the laptop is turned off (not hibernate, sleep, etc., but off).
If it will charge then, the problem is most likely not the battery but the charger cord. When they are damaged (and you don't have to see the damage) they may not put out enough power to both run the laptop and charge the battery.
Now if it won't charge at all when turned on or off, but the charger cord will run the laptop, then you need a new battery.
No matter which it is you need, cord or battery, do yourself a favor and go OEM not aftermarket. The aftermarket may seem like a great deal due to pricing, but unlike other aftermarket stuff which works fine, laptop cords and batteries are not in...