Sometimes I just force myself to sit down and write. It doesn't always work, but when you can get yourself focused on writing for about an hour or more, your mind goes into a state of flow, and your creative ability improves.
Other times it's just when an idea strikes. Mostly this only prompts...