My method is simple and has only four steps. 1. Write something cool and put it online for free. 2. Wait 4 to 5 years. 3. Gather all the emails asking if they can license it or pay you to adapt it. 4. Then slap on a price/marketing page emphasizing what everybody asked for.
http://websequencediagrams.com is my SAAS business. When I was working on 3GPP at RIM we had to spend hours in Visio moving boxes around, and pasting the results into word documents. It was a challenging layout problem. By 2007 I made a python script that did sequence diagrams automatically and put it online. I began to get emails from companies saying they wanted to license it, so I obliged. After I left RIM, I converted it into a freemium product. I have about 400 users paying $9 to $15/month.
http://zwibbler.com gets about 70 visits a day. It's a javascript drawing library with full-service from me. Again, it started as a free HTML demo, and I began to get emails requesting me to adapt it for pay. Instead, I created the front page that offers a complete solution for $1500. By answering emails and talking on the phone, I can get 3 or 4 clients a month without even trying. I figure out what they want and reposition the buttons to do it.
My favourite is http://rhymebrain.com because I don't have to do anything. Google just transfers $1-2K into my account every month for Adsense.