All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger.
If you are possessed by Jinn, then the remedy is to seek its treatment by reciting the verses of the Quran and the supplications stated in the Ahadeeth of the Prophet Muhammad in performing Ruqyah.
For more benefit on this subject, please refer to Fataawa 81559, 81643 and 81667.
However, you have to avoid taking seriously what you have seen in your dream or at the time of sleep, otherwise it could destroy your life and sow hatred between you and your husband. Try your best to follow the Sunnah when going to bed, such as performing ablution, sleeping on the right side and reciting the supplications before sleeping. The Prophet said: "When you go to sleep, perform ablution just as you perform it for the prayer and then lie in bed on your right hand side." [Muslim]
As regards how to prevent your husband from contacting that woman, then if you are sure that he contacts her without any sound reason, then you are obliged to exhort him and remind him of Allaah, that Allaah does not approve of such actions. First, you should seek Allaah's help and then the help of some righteous and rational people who may influence him provided you don't fear that if they exhort him, it may lead to a greater or preponderant harm/disadvantage.
Also, you may suggest to the Imaam who delivers the Friday speech in your mosque to tackle in his speech this subject that it is prohibited for a man to establish an affectioante or friendly relationship with a non-Mahram woman, and that this matter is very serious and has a bad fate and consequences.
Finally, we advise you to be patient in advising your husband and you should believe that Allaah will show you a good end.
We also supplicate Allaah to guide your husband to the right path and help you correct him, as Allaah is able and capable to do so.
Allaah Knows best.