set %lines (1,$lines(C:\Users\CvdEeden\Desktop\DJ-Serv\quotes.txt))

Is this supposed to be using $+() ? If not, $lines won;t be evaluated.

set %lines $+(1,$lines(C:\Users\CvdEeden\Desktop\DJ-Serv\quotes.txt))


You say /quotewrite, but in the quotewrite alias it is wanting to add $2-. Can you verify it is getting $2- and $nick from the text event?