Superheroes from both DC and Marvel are notorious for taking this to ridiculous extremes. The most obvious example is Batman's refusal to kill even The Joker, despite knowing that he's a purely evil, irredeemable, sadistic monster who cannot be reformed and who will simply go on killing innocent people just for kicks (which leads to some very Unfortunate Implications). When Joker then goes on to kill Jason Todd, the second Robin, Batman comes damn close to breaking his rule, but didn't in the end. Unfortunately, this would come to bite Batman later: when Superboy-Prime'sCosmic Retconresurrected Jason, the fact that Batman never avenged his death led him to assume the mantle of Red Hood, an Anti-Villain who opposes Batman's no-kill ideology, thus pitting the two of them against each other.
The protagonists of Sin City each possess this trait. Despite their violent and sadistic nature, they will still put their lives on the line and suffer greatly for the sake of those they wish to protect.
In Usagi Yojimbo, when a character makes a decision and says, "I am adamant!", that means literally nothing, especially death threats, will make them change their mind. For instance, a swordsmith said this in refusing to sell one of his swords to a brutish samurai and when threatened to be killed, he all but said, "Kill me if you want, but that just guarantees I won't sell you anything."
Usagi sums up his feelings for this trope when he says "What fools we have in this world, that confuse honor for weakness."
More of a case of obsession before reason, but Rorschach from Watchmen has "Never Compromise" as his motto in the face or murderers and rapists, and the people who would stop him. This leads to his death as he refuses to allow Ozymandias to go free, despite that this would render the death of millions meaningless and restart the cold war. However he is also doing this because, it also allows the person responsible for the most deaths in human history history to walk off scot free, and he is disgusted with the idea that the only way to save humanity is to deceive and slaughter it.
In ROM: Spaceknight, the title character found himself in such a situation when he had captured a disguised Dire Wraith disguised as a human scientist, but her security staff, unaware of her true nature, had arrived to help her. The Dire Wraith dared him to banish her at the cost that it will appear he killed her and he would likely never be able to convince humanity of the truth. Rom considers this, but since a friend had sacrificed his life to free his main weapon, he cannot have that sacrifice be for nothing. So, he banishes her and prepares to deal with the consequences.
Yorick of Y: The Last Man is like this for the first part of the series. Two major examples: He's the last living male human, yet tries not to cheat on his girlfriend who is half a world away. He comes across a town that's entirely populated by convicts from the near by women's correctional facility. Despite this, it seems to be one of the few nice places After the End and is actually very stable. Yorick wants to turn them in to the government.
It should be noted that Yorick has a nasty combination of Survivor's Guilt and general Catholic Guilt, along with a variety pack of mental hang-ups, that cause him to do not necessarily what is right, but what is mostly likely to make people hate and want to kill him (Honor Before Survival, in other words).
The Transformers: There was the time Optimus Prime allowed himself to be destroyed because of a video game that he and Megatron were connected to in order to decide a battle. A game that he'd won, but by taking several NPCs out with Megs — something he'd never do in reality, so he considered himself the loser.
Further compounded by the fact that he killed the NPCs by accident. Given that they were in an opaque structure, Optimus would not have been able to know they were there either way. Nonetheless, Optimus declares that his victory was by cheating.
Linkara: That's not what 'cheating' is, you stupid truck!
To be fair, Megatron didn't like it, either.
Jubilee of the X-Men takes the superheroic code against killing to a foolish extreme in one story. While escaping from Operation: Zero Tolerance (who had been torturing her for days), she seriously injured one of the guards — and broke off her escape to perform CPR on him.
Jubilee: You wanna go around killing people? That's your choice. But don't think for a fraction of a second you're gonna make a murderer outta me.
In Incorruptible - a spin-off of Irredeemable - Max Damage made a Heel-Face Turn in response to The Plutonian's epic Face-Heel Turn. In the process of "making a clean start of it", he destroys billions of dollars in currency he'd stashed away over the years and destroyed most of his old gear and hideouts. Which is cool and all, but wouldn't all those resources actually help fight The Plutonian?
Although the comic does frame this as the supervillainous equivalent of Going Cold Turkey, since Damage is trying to change his ways completely and feels that having the relics of his old life would make it too easy to slip back into old bad habits, same as a recovering drug addict doesn't keep a whole load of drugs stashed about the place just in case.
In the DC comic Birds of Prey, a group of Chinese uber fighters called the Twelve Brothers in Silk are said to be at Lady Shiva level of ability but routinely work for b-rate crime bosses by being challenged to defend their "honor." The claim being that they can't do the job, not that it's below them.
In the first WolverineLimited Series, Logan is aghast to learn that not only his girlfriend, Yashida Mariko, is married, but it was on the orders of her father which she obeyed without question. His friend makes it clear that she did it as a matter of personal honor and she literally would rather die than violate that. Logan goes to see her, but is frustrated that she is adamant about keeping her honor in obeying her father, even while her husband abuses her. Fortunately, Mariko eventually realizes that her father is besmirching their family's honor with his evil and plans to kill him and commit suicide in recompense. Fortunately, Wolverine beats her to it and Mariko considers the matter properly settled.
Then there's Spider-Man. With great power comes many low-paying jobs, no respect, a legendary chain of disrupted relationships and break-ups, and many, many injuries. But he never resigns for long. Because he's Spider-Man, and he has a responsibility.
In an early Avengers tale, the Swordsman joined the team as a mole in order to bring them down from the inside. When the time came to kill his teammates via a bomb provided by the Mandarin, Swordsman relented, stating that it would be cowardly and dishonorable to kill the Avengers while they slept.
In Jonathan Hickman's New Avengers, the Illuminati become aware of a cosmic Disaster Dominoes event — universes are colliding, Earth-first, and destroying each other — and that when two universes begin to collide, the event can be halted by destroying one of the Earths. Captain America is the only member of the group who will not entertain the idea of destroying a planet to save everything else so they wipe his memory and expel him.
In the first Marvel vs. DC/DC vs. Marvel crossover miniseries, Wonder Woman discovers The Mighty Thor's hammer and takes it up, becoming the God(dess) of Thunder. When Storm comes to challenge Wondy, she muses that she could easily defeat her with her new power, but discards it, finding it utterly unfair. Storm easily takes her down.