Have a look at this circuit, if it works with a SD-card, it will work with a SIM too.
Simply, power down the GSM modem, switch the card and power it on again.
If the GSM modem has a pin for signaling "Sim-card-holder open" you could use that too, signaling the GSM modem that the card was removed and re-inserted, without powering down the modem.
// Per.