This paper presents a new idea by correlating the effective charges of ions in solar energetic particles with their energies during the acceleration in flaring region. Based on ionization potentials of elements and taking account of the effect of thermal velocities of electrons in plasma of flare active region, one formula is suggested to calculate charge states of the elements C, N, O, Ne and another formula for Fe. From the formulae, the calculations for the elements are in good agreement with the observations.