We report on strain measurements in Ni-Mn-Ga, Ni-Mn-In, Ni-Mn-Sn and Ni-Mn-Sb polycrystalline alloys as a function of temperature and magnetic field. Experiments are carried out in the austenitic and martensitic phases of the alloys. It is shown that in the cubic phase the magnetostrain is similar for all systems but by contrast very different behaviour is found when a field is applied in the martensitic phase. In the latter case, magnetic shape memory and magnetic superelasticity is obtained for Ni-Mn-Ga and Ni-Mn-In, respectively. The physical reasons for the different behaviour are discussed.