Patience and perseverance
Writing has been a passion of mine for many years. I have had eight books previously published and my first novel is coming out in October 2016.
I believe that the secret to successful writing is simple. To sum it up in a single word: perseverance.
You have to plan and self-criticise and revise ruthlessly. You have to learn to accept criticism from others and rejection from publishers and literary agents.
If in spite of all that you persist in writing and try to develop your skill; if you can come up with a good idea or, if you're a novelist, a good plot, then (with sufficient persistence) you will be published.