In a certain old age home they forgot to remove the light bulb from the fridge and the question arose if we can remove it with a shinui in order to save the many people there from chillul shabbos when they open the fridge [they wouldn't necessarily listen if we told them not to open it].
The gemara says וכי אומרים לאדם חטא כדי שיזכה חברך - Do we tell someone to sin in order that his friend should have a merit? AVADE NICHT! Of course not. From this gemara it emerges that we would not be allowed to do the minor sin of opening the fridge and removing the light bulb with a shinui in order to save others from sin.
But it is not so straightforward. Tosfos asks from the gemara in Eiruvin that says that a chochom can do a small aveira in order to save an ignoramous from a more serious aveira. This apparently flies in the face of our gemara. Tosfos offered a number of answers to resolve this question.
1] When the sin was done because of the person himself he is allowed to sin in order to prevent his friend from sinning. To that the gemara in Eiruvin refers.
2] In Eiruvin the איסור was not yet done in contrast to our gemara where he had already put the bread in the oven which was an איסור. When the איסור was not yet done it is permitted to do a smaller איסור to save from an eventual איסור.
According to the first answer when the manager of the old age home was guilty of not removing the light bulb before Shabbos - it would be permitted to remove it on Shabbos with a shinui.
According the to the second answer it would be permitted for every person to remove it because the איסור had not yet been done.
Tosfos also says [based on a gemara in gittin] that for a "mitzva rabba" - a big mitzva, it would be permitted to do a smaller aveira. Saving so many people from sin is probably subsumed under the category of mitzva rabba.
Tosfos ALSO says that if the sinner would be a פושע [negligent] it is FORBIDDEN to sin to prevent him from doing so. In our instance maybe the lack of understanding about the severity of opening up the fridge would be considered פשיעה and thus אסור to help by removing it beforehand.
Practically
According to the מגן אברהם [in סימן רנד סקכ"א] if the sin would be the fault of a specific person - he would be allowed to commit a sin in order to prevent his friend from committing one [answer 1]. In our case then הלכה למעשה it is permitted for the manager to remove it.
According to the שער הציון [in ש"ו מ"ו] for a mitzva rabba it is permitted for anyone. Then we have another היתר in our instance הלכה למעשה.
There is so much more to say. Maybe a different time...:-)
עפ"י חשוקי חמד עמ' 50-52