Well if it will only turn on when connected to the charger, I would say the battery is toast and needs replacing. Hence why it won't run on the battery alone.
If the device is still under warranty, then I would contact the manufacturer about a repair/replacement. If it isn't under warranty, then you will have to look into replacing the battery yourself, or hiring someone to do it for you.
NOTE: Avoid after market laptop batteries. While I am a fan of most after market stuff, and much of it works really great, laptop batteries and laptop charger cords do not fall into this category. Best to go OEM in such cases.