Hi @ First Bank Texas
If it works on AC but not on the battery, then perhaps the battery is failing (or has failed) and needs to be replaced.
What does the Power LED indicate when you connect the AC to charge the battery?
If it shows charging but still continues to flash slowly after a very long time (think 3-4 hours) then the battery will most probably need replacing.
How old is the speaker? If older than 2 years then perhaps the battery is at the end of its' useful life. Even rechargeable batteries have a lifespan, (depending on use of course)
Here is a link to the ifixit Harman Kardon Onyx Studio 2 Battery Replacement guide, which may be of some help.
Replacement batteries are available online. Just search for Harman Kardon Onyx Studio 2 battery to find suppliers that suit you.