"You do not have, because you do not ask God. When you ask, you do not receive, because you ask with wrong motives, that you may spend what you get on your pleasures."1
One reason we don't get some prayers answered is because we are praying the wrong prayer. Not necessarily because of a wrong motive, but because we focus our prayer on the symptom and not on the cause of the problem or illness.
There's a well-known hymn that says, "O what needless pain we bear, all because we do not carry everything to God in prayer." We could also sing, "O what needless pain we bear, all because we do not pray the right prayer."
For example, if I have a stomach ulcer or a headache, I tend to ask God to heal my ulcer or my headache. This is what I mean by focusing our prayer on the symptom. While some ulcers have a biological cause, some are caused not by what I eat but by what is eating me, and then what I eat aggravates the problem. I've never had an ulcer and rarely have a headache, but when I do have a headache, it's usually because I am either mad about something or am under a lot of stress.
If I am going to ask God for healing, I need to admit not only the symptom, but also ask him to give me the insight to see, and the courage to face, anything in my life that is causing my illness, and then ask him for the help to resolve it.
It is unrealistic to ask God to heal my symptoms if I fail to face and deal with the causes. If he did, he would be irresponsible. It is possible, however, to exchange one symptom for another because if we don't deal with the cause of our problem, in time it will come out another way—probably a worse way.
I recall hearing one man claim that the moment he became a Christian, God delivered him from his alcoholism. He may have quit his drinking but it was rather obvious that he was now (or still) a rage-aholic, which quite possibly was a cause behind his alcoholism.
This principle applies not only to physical ills but to many other problems as well. I learned this lesson the hard way. After many years trying to resolve a frustrating situation I was in, I begged God to give me the courage to face the truth of what I was contributing to the problem. Within two weeks I saw what an enabler I had been for so long. Once I saw the truth, I knew exactly what I needed to do, which in the doing resolved my part of the problem.
Suggested prayer: "Dear God, with every problem, illness, conflict, and challenge I face, help me to pray the right prayer and see any cause behind my sickness or problem and what I am contributing to my situation. Help me to resolve whatever cause there might be so that I will clear the way for your deliverance, healing, and freedom. Thank you for hearing and answering my prayer. Gratefully, in Jesus' name, amen."
1. James 4:2-3 (NIV).