Hopefully you'll recall that electro magnetic induction depends on the amount of flux linked changing over time.
Operating the switch creates a large rate of change of linked flux in the secondary coil.
leaving the switch open or closed does not produce a changing amount of flux in the secondary coil.