Gas infall and outflow are critical for determining the star formation rate and chemical evolution of galaxies but direct measurements of gas flows are diffcult to make. Young massive stars and HII regions in the halos of galaxies are potential tracers for accretion and/or outflows of gas. Gas phase abundances of three HII regions in the lower halos of the edge-on galaxies NGC 3628 and NGC 4522 are determined by analysing optical long-slit spectra. The observed regions have projected distances to the midplane of their host from 1.4 to 3 kpc. With the measured flux densities of the optical nebular emission lines, we derive the oxygen abundance 12 + log(O/H) for the three extraplanar HII regions. The analysis is based on one theoretical and two empirical strong-line calibration methods. The resulting oxygen abundances of the extraplanar HII regions are comparable to the disk HII regions in one case and a little lower in the other case. Since our results depend on the accuracy of the metallicity determinations, we critically discuss the difference of the calibration methods we applied and confirm previously noted offsets. From our measurements, we argue that these three extraplanar HII regions were formed in the disk or at least from disk material. We discuss the processes that could transport disk material into the lower halo of these systems and conclude that gravitational interaction with a companion galaxy is most likely for NGC 3628 while ram pressure is favoured in the case of NGC 4522.