Carbon dots (CDs) show great application prospects in various fields such as optical devices, biomedicine and sensors due to their excellent optical properties. In this work, novel B, N-codoped CDs were prepared through a facile solvothermal method using the hyperbranched polyborate as the precursor. To our surprise, the prepared B, N-codoped CDs exhibit unique "dual-excitation and single-emission" fluorescent characteristics in water- -ethanol binary solvents mixtures. The B, N-codoped CDs have two excitation bands at 255 nm and 345 nm, and only one emission band at 410 nm when the water-ethanol solvent mixture ratio is 9:1. The experimental investigation shows that it is due to the fluorescence resonance energy transfer between the solvent mixture and the CDs when the ratio of water to ethanol is 9:1, which leads to the double excitation and single emission phenomenon of B, N-codoped CDs in water-ethanol solvent mixture. In addition, the prepared CDs have a unique multi-ion detection capability, and the CDs can realize the quantitative detection of Co2+ and Cu2+ as well as the qualitative detection of Fe3+. This work greatly expands the application of carbon dots in metal ion detection and provides a new perspective for the development of functional CDs.