Just an aside, but don't do this (spray paint PVC pipe). Most of the pigments used in paints that you can find in the home store aren't toxic, but by coating the outer surface of the PVC, you're risking a poor PVC glue bond. PVC glue works by actually dissolving the PVC, so you don't want any sort of barrier to penetration.
But if you'd like something other than white PVC, there's two good alternatives: either buy the PVC that's had the color already added to it when the pipe was extruded, or dye the PVC yourself by mixing an oil-soluble woodworking dye into methyl ethyl ketone (available at the home store), and coating the PVC. If you want to do this, remember that you must do it outside - MEK stinks, is flammable, and is toxic in concentrated amounts.