It's not likely the battery -- which won't charge with an unrecognized adapter.  The two most common causes are the DC plug on the adapter and the DC jack.  If the latter is evidently loose, replace that first.  
The battery won't charge, it's always 0%.  I updated the firmware to no avail.  Dell diagnostics give "charger - the AC power adapter wattage and type cannot be determined. The battery may not charge".  The laptop needs the charger plugged in all the time to work. It's a two-year old laptop.  The DC hack seems a bit loose, it unplugs itself a bit too easily.  I tried with another test charger, same issue.  I suspect the dc jack inside the laptop needs replacing rather than the battery being bad. Any help much appreciated
Battery not charging in my DELL Vostro 3500 P90F