I recommend a little treatise called "Uniformity with God's Will" by Alphonsus de Liguori. It is an excellent read.
I guess the best way to "know" the will of God is being in sanctifying grace. When your soul is clean of sin and you are in state of grace, the Holy Ghost can dwell in you and "guide" you.
Accepting truly Our Lord's will is of vital importance in our way of salvation. One must be humble and renounce self and gladly accept everything that God sends our way, joy and sorrow, happiness or tribulation. We must be grateful and know that God wants the best for our souls. We need to have a child-like trust in His infinite wisdom.
“Prosperity does not lift me up, nor adversity cast me down. I direct all my prayers to the end that God’s will may be done fully in me and by me”.