I know a lot of writers who will make soundtracks for different projects, or who have particular songs or albums that inspire them as they write. For the most part, I can't have music on while I'm writing. It's too distracting. But I definitely will use music in other ways in regards to my writing.
I Burn For You is an example of music inspiring a story idea. I forget what finally prompted me to write the story down, but that was one time where I had the song playing as I wrote, trying to get the rhythm into the prose a little.
My short story "Good Neighbors" was inspired by a scene from the movie The Wicker Man. (The original version, not the remake.) There's a scene where a woman is trying to seduce the hero by singing to him through the wall of his room and tapping on the walls, and it's hot, hot, hot. (And has a catchy song too!)
Scent and Shadow took me a long time to write, so there was a lot of music that helped keep me in the mood. While I didn't listen to anything while actually writing it, I would play particular songs in the car or before I started writing to try and capture the feeling I wanted. A few favorites from the playlist are:
"Poison" by Alice Cooper
"Voodoo" by Godsmack
"Wulf" and "Slave to Evil" by :wumpscut:
"Ribbons" by Sisters of Mercy
As well as large sections of Pretty Hate Machine by NIN, Violet by The Birthday Massacre, and The Lost Boys Soundtrack.
One late addition was "Beg Steal or Borrow" by Ray LaMontagne & The Pariah Dogs. Although it was a bit of a switch-up from the rest of the playlist, the song very quickly became Amanda's theme.