Usually this happens when all of the options in front of us are bad (for instance, every option involves harming someone or our self). For instance, if you decide X you will hurt one person, and if you decide Y, you will hurt another.
In some situations in life, there is a clear right and wrong. Sometimes finding what is right or wrong can be challenging because we often have to sift through our personal desires, cultural expectations, assumptions about what is good in life, biases, and so forth. Only God has absolute wisdom about all things, and when we are in a particular situation, we cannot see the overall picture that God does. Often, we understand the divine wisdom of something after years or even decades.
In other situations, there isn't a clear right or wrong. Sometimes all the choices are morally acceptable even if not ideal. We are free to choose (and responsible for our choice). In situations like that, contemplating the verses of the Qur'an, seeking advice from trustworthy people, prayer, and istikhara can help. When a person seeks divine guidance, it is usually delivered quickly, if we are open to it.