Hi AV88, welcome to Psych Central!
About two years ago, when I was new here, another member started a thread about intrusive thoughts. It's always been one of my favorites and I thought I'd leave you a link to it:
Sexual and Gender Issues > Unwanted Sexual Thoughts.