Sometimes, during the course of reading something or watching something, I'll get annoyed by something a character does and put the book down or turn off the television show. Permanently. when that happens, I'm usually thinking "whatever. Character X would never do that!"
Let me give you an example--a long, long time ago, in a land far far away, I used to watch a show called Joan of Arcadia. If you didn't see it, the plot's not really important,* but what is important is that there was a guy who liked her named Adam. Adam was a really sweet kid, an artist, kind of spacey and dreamy, so much so that he called Joan "Jane" for most of the show, but a basically awesome kid. And eventually over the course of the show's two seasons, Adam and Joan end up being a couple. Then, at some point in the show's second season, Adam cheats on Joan. And not just "I kissed this girl and it will never happen again," but totally "I used this other girl to have sex with who I don't even really like. MORE THAN ONCE!" cheating.
And that was when I stopped watching the show, saying to myself "Adam would never do that."**
And sometimes that's the right answer, right? We've all read books in a series, or seen a television show run aground, where the creators don't have any idea what to do next, so characters start acting contrary to their natures just to create drama. Almost all long standing series have moments like that, and writers would be well-served if they could find some other way to create drama and avoid that mistake.
But sometimes that's not the answer at all.
Sometimes, when the reader or viewer thinks "Character X would never do that" what they mean is that they can never forgive Character X for that. The two things are closely related, but not exactly the same: "Character X would never do that" means that there is a problem with the characterization. It seems like what we the readers understand about the character doesn't mesh up with his or her current actions.
But "I could never forgive Character X for that" means that Character X has crossed some personal line in the reader's mind that cannot be uncrossed. Sometimes it's crossed because of the problem of bad characterization, but most times it's just a unique wrinkle of the reader's personal map and there's no predicting it and no changing it.***
So, as a writer, what is one to do? Correction of the first problem is the easiest, I think. Avoid bad characterization. Problem solved! :) Of course, it's never exactly "easy" to do that sort of thing, but one way to do it is to reveal your character's flaws in little ways so that the Big Bad Thing seems to connect to those previous little things. A perfect example is the first season of the show Veronica Mars. In that season, the central question is who killed a teenaged girl.**** The character who has actually done it (and HERE BE SPOILERS, in case you care) has very violent tendencies, which we the audience see when he whips his son with a belt as punishment, and when he beats up a young man who has punched his daughter (and who totally deserved to get his ass kicked, by the way). So we see his violence in a negative way, when he hits his son, and in a (sort of) positive way, when he protects his daughter, and when he's ultimately revealed as the killer, it makes perfect sense. He would kill this teenaged girl if she did something to threaten him (which she did). He's a violent guy.
Correction of the second problem? Oh, it's impossible. Don't even bother to try.
Okay, I'm kidding, but I'm also sort of serious. If you sanitize your stories so that no one will ever be offended by them, well, congratulations. You just wrote the world's most boring story. But you should, as a writer, be aware that some things put people off more than others. This is genre specific, of course (like the mutilation of bodies isn't that unusual in a thriller about a serial killer, but in a YA book about first love? A little unusual). But if a character does something extreme (and all characters should, frankly), you should be making a conscious choice to lay the groundwork for that action. So that you, as the writer, can feel confident that it's the second line you crossed and not the first.
* It was about a teenaged girl named Joan who thought she could see God.
** I'm not the only one who had trouble buying this turn of events, by the way. Here's what Television Without Pity recapper Deborah had to say about it when it happened:
Even if I bought this unconvincing turn in his character -- which I don't -- I would have a lot of trouble buying his casual attitude about it, and this confession to Grace, with an expectation of support riding on its coattails. I could believe he'd admit to her what he'd done, but only because he found it unbearable to keep to himself and had no one else to tell, not because he almost blithely assumed her support. Come on -- he's madly in love with clingy-clingy Joan, and he's a virgin (or was, anyway), and he's pretty sensitive to boot. This is not the Adam they've been writing for two seasons, no matter how many "horny seventeen-year-old boy" explanations people offer up. The only possible explanation I'm entertaining is a self-sabotaging impulse driven by depression secondary to being in a suffocating and unfulfilling relationship. Still, even that just doesn't sit right with me, because the writers are making it about the sex. And I just don't believe that's the greatest driving force in Adam's personality.***One of my personal lines is the killing or injuring of animals if it's done in a serious piece. The death of the dog in American Psycho wasn't a problem for me, for example, because I see that work as a satire. I didn't take it seriously. But I watched every episode of The Wire with baited breath when Ziggy got a duck. Given the grim nature of The Wire, I was relieved when the poor thing just drank itself to death.
****Veronica Mars is like Twin Peaks without all the owls and the evil spirits and crap. By which I mean it's like Twin Peaks, only good.