Joseph's trouble started when he shared a dream that God gave him. His brothers were already on edge with him, because of their jealousy for their father's affection. When Joseph heard from God, however, it seemed to 'throw fuel on the fire.' This started a chain of events that ultimately lead to Joseph's brothers selling him into slavery.
It was this slavery that became the path to fulfilling the dream that God gave Joseph. While it seemed that Joseph's dream caused all these trials and troubles in his life, those trials were actually causing Joseph's dream to become reality. Had Joseph kept quiet, made peace with his brothers at any cost, and avoided these terrible trials in his life, the dream that God gave Joseph would have had no path on which to travel.
Often, God's calling and direction in our lives lead through terrible tragedy or difficult circumstances. This is not an accident. These are not obstacles to overcome in order to fulfil God's plan for our lives, but rather the very path by which God's glory will be manifest.
The question is, will you be like Joseph, and say in the midst of your trials, "...Fear not: for am I in the place of God? But as for you, ye thought evil against me; but God meant it unto good, to bring to pass, as it is this day, to save much people alive." (Genesis 50:19b-20)
Genesis 37:5, "And Joseph dreamed a dream, and he told it his brethren: and they hated him yet the more."
Genesis 39:2-3, "And the LORD was with Joseph, and he was a prosperous man; and he was in the house of his master the Egyptian. And his master saw that the LORD was with him, and that the LORD made all that he did to prosper in his hand."