a metal atom has 2 valence electrons When it forms an ion its ionic charge would be

The ionic charge of the metal atom would depend on the number of electrons it gains or loses. If it gains two electrons, its ionic charge would be -2. If it loses two electrons, its ionic charge would be +2.