Press on the release clips on each side of the battery pack to remove it from your power tool or battery charger. Determine how the battery pack's casing is held together.
Remove any screws fastening the battery pack's casing together. If necessary, pry apart the casing with a flat-head screwdriver. In some cases, you may have to cut through the casing's plastic with a soldering iron.
Attach a chisel-tip soldering iron into your soldering gun. Heat up the gun for a few minutes, and run the tip along the small crease in the battery pack's casing. Remove the top section of the battery pack's casing. The battery cells are usually attached to the top part of the battery pack.
Examine the battery cells to determine which end of each battery is the positive (+) or negative (-) end. Use a battery tester to test each cell to see which cells are working, and which cells are not.
Use the heated soldering iron tip to desolder, and disconnect the bad NiMH battery cells from the battery circuit. Use the same soldering tip and some solder to connect the new NiMH battery to the connector in the battery circuit. Repeat this for each battery cell you replace.
Reassemble the battery pack. If you had to cut open your battery pack casing, you will have to simply duct tape the casing back together.