Let's see... Say a friend talked you into doing something that you didn't want to do. Before you did it you could say "If it weren't for you I would not be doing it/this."
and, in the end, it worked out great. You could then say... "Thanks! If it hadn't of been for you, I would never have done it."