I am sure someone is going to correct my bad grammar in the title, but at least you understand what I am saying. I was listening to a sermon on 1 Corinthians 3 tonight. The point made was that there are people who like to think that they know everything but are the greatest fools. They are unteachable and hard to get along with. They won't listen to what you say because they think they know the right answer already.
In reality, they would never hear what you are saying, only what they perceive you are saying that they disagree with so that they can tear it apart. I have this happen to me frequently when I am trying to share something with a group of people. Someone, particularly someone younger than me, will say that I am saying something that I am not saying and will tell me how wrong that it is or how silly I am for thinking it. Then they may tell me that I should go back and read a certain passage or listen to a particular sermon.
The advice this preacher gave is that you can't do anything with a person like that other than taking a hands-off approach. Leave them alone in their ignorance. Let them go and don't try to help them see the light. They are at the point where they are beyond help (at least for now). Sometimes we think we have done something wrong. I don't think we have usually. There may be some unperceived resentment toward us because we remind them of someone they don't like. Yes. I know they shouldn't think that way but that is just the way people are, especially immature Christians. They have not learned much love for others yet and are pretty proud of their own knowledge.
Maybe they feel they have all the answers and are qualified to be everyone's counselor. It is actually these people who are the most incapable of offering any helpful advice and more often than not, their inner life is a nervous wreck. Yes, you can pray for them, because in this case they would be considered your enemy. You can show love to them even when they don't do it in return. That is what a mature Christian is called to do.