This is a pretty powerful piece of scripture. When we don't get what we want we need to examine ourselves and see if these scriptures apply to our situation.
God says no for other reasons too -- sometimes because there is something better than what we are asking for; sometimes because His plan is far bigger and involves more people than we realize and He has to work all the pieces together; sometimes because we ask at the wrong time. God's timing is perfect. Ours isn't.
But we would be wise to examine our own hearts to make sure the above verse isn't ringing true in our lives when God does say no.