In doing some research regarding such an issue, there appears to be a lot of folks having this issue, especially with HP/Compaq laptops and Windows Vista.
While there isn't ONE foolproof way to fix this issue there seems to be a couple things that work more often than any other. Give them a try, they can't hurt!
First, with the laptop plugged in, booted up and running normally, simply take the battery out while it's still running. Leave the battery out for a couple minutes to let Vista recognize that the battery is missing. Next, simply put the battery back into the laptop and wait about 30 seconds. It may just start charging!
If that doesn't work, try the following steps.
1. Turn off the laptop
2. Remove the battery and AC connection.
3. Hold the power button for 1 minute to drain any remaining charges on the circuit board.
4. Install the battery
5. Plug in to AC power. Do not power up the laptop! The charge light should now be solid, not flashing.
6. Allow the laptop to charge for a while without powering it up yet.
Turn on the laptop and see if the battery continues to charge.
It seems there may be an issue with Vista charging a fully spent battery. However, the above charges the battery above it's dead state without loading Windows. Once your start the computer again, the battery isn't fully dead, so Vista can charge it again.
Again, it doesn't work for all cases, but definitely worth a shot! If you want to read oodles of comments about people with this issue, head on over here.