Paint spraying machines use electrostatics to prevent paint wastage. The paint gun is given a strong positive charge by a high voltage positive needle. All the paint droplets leaving the gun acquires a positive charge. The metal surface to be painted is given a negative charge. According to electrostatics, like charges repel each other, while unlike charges attract each other. This has two effects on spray painting: All the paint droplets, being positively charged (same charge), repel each other and hence are spread over a larger surface area. This ensures greater surface coverage. Since the droplets and metal surface have opposite charges, they attract each other. Hence droplets are attracted to the metal surface and hence the wastage of paint (by dripping or falling on walls and floor) is less.
Hope this helps.