This paper studies the effect of a charged impurity together with or without an external homogeneous electric field on a quantum ring threaded by a magnetic field B and containing two electrons. The potential caused by the impurity has been plotted which is helpful to the understanding of the electronic structures inside the ring. The deep valley appearing in the potential curve is the source of localization, which affects seriously the Aharonov-Bohm oscillation (ABO) of the energy and persistent current. It also causes the fluctuation of the total orbital angular momentum L of the pair of electrons. It is found that the appearance of the impurity reduces the domain of the fractional ABO. During the increase of B, the domain of the integral ABO may appear earlier when B is even quite small. The transition from the localized states to extended states has also been studied. Furthermore, it has deduced a set of related formulae for a transformation, by which an impurity with a charge ep placed at an arbitrary point Rp is equivalent to an impurity with a revised charge ep placed at the X-axis with a revised radial distance Rp. This transformation facilitates the calculation and make the analysis of the physical result clearer.