Had a few problems with charging mine. I found problems can occur in pretty much any aspect, so test each one by changing it if you can!
Kernel, ROM, charging adapter and USB cable.
If none of these work, its probably the charging port/connection in your device. Have a look at it closely to make sure the connection is as secure as it should be.
Failing all of these, pop the back off the device and take another look at the connection. My port somehow seems a bit larger than my cable so I force it a bit tighter every week or so - possibly bad in the long run but definitely works for now
Sent from my HTC Desire C using xda app-developers app