Grieving people need to know about the grieving process and some of the things they may experience such as not to be led by painful feelings. When a major loss occurs, this isn't the time for a person to make serious decisions or deal with other issues that may produce anxiety or be emotionally upsetting.
Being angry with God is quite common. People frequently ask, "If God is good, all-powerful, and full of love for us, why didn't He stop the thing that caused the pain?" This is where Satan seeks to build a wall between God and the hurting person. He seizes the opportunity to say, "God isn't good, and He can't be trusted." However, we know according to the Word of God, the truth is not in Satan—he is a liar and the father of lies.
James 1:12-13 says, blessed (happy, to be envied) is the man who is patient under trial and stands up under temptation, for when he has stood the test and been approved, he will receive [the victor's] crown of life which God has promised to those who love Him. Let no one say when he is tempted, I am tempted from God; for God is incapable of being tempted by [what is] evil and He Himself tempts no one. Verse 17 goes on to say, Every good gift and every perfect (free, large, full) gift is from above; it comes down from the Father of all [that gives] light, in [the shining of] Whom there can be no variation [rising or setting] or shadow cast by His turning [as in an eclipse].
In other words, God is good, and He cannot be anything else. Furthermore, He isn't one way one time and another way another time. He doesn't change. He is good, and that's the way He is. But what about the original question? Since God is good and all-powerful, why didn't He stop this thing before it brought all the hurt and pain? To be very honest, these are questions we don't have completely sufficient answers for. First Corinthians 13:12 says, ...Now I know in part (imperfectly).... Trust will always require us to accept unanswered questions! We want answers to everything, but we must come to the place where we're satisfied to know the One who knows and place our trust in Him. Being mad at God is foolish because He's the only One who can bring the needed help and comfort to the grieving or bereaved person.