In Act 3.3 of Shakespeare's Hamlet, Hamlet tells the reader why he doesn't kill Claudius and achieve his revenge:
Now might I do it pat, now 'a is a-praying,
And now I'll do't--an so 'a goes to heaven,
And so am I revenged. That would be scanned.
A villain kills my father, and for that,
I, his sole son, do this same villain send
To heaven. (Act 3.3.73-78)
Hamlet assumes Claudius is confessing his sins. According to Hamlet's Catholic beliefs, Claudius' soul would be wiped clean and he would be forgiven and if killed, would go straight to heaven. Claudius is not confessing his sins, but Hamlet assumes he is. Thus, he chooses not to kill him and send him to heaven.
This, of course, is probably the climax of the play. When Hamlet makes this decision he is playing God--dealing with human salvation, not revenge. Salvation is God's business, not Hamlet's. Because Hamlet walks away, innocent people die, including Hamlet himself.