My advice, graff wise, like ^^^ mentioned, a detailed excuse to why you were in a certain area, what you were doing there, where you were coming from, where you are going, etc. is VERY VERY important. If you are not alone, make sure the person/people you are with know the story exactly as you do. It doesn't matter what you were doing, it matters what they think you were doing, and what they can prove. If you provide your answers calm and smoothly, there should be no search. Most times you are stopped the cops don't immediatly suspect you of one certain thing. They ask you questions to raise suspicions about any illegal activity.
The second thing is, always were gloves, and if you have a long sleeve shirt or jacket on, pull the sleeve back slightly when you paint, so no backspray (mist) gets on your clothing (ESPECIALLY SILVER & GOLD PAINT).
Personally, I try to wear one certain color when painting. Not black, it's too suspicious when your dressed in all black at night. Say if I have dark blue jeans on, I'll have a navy shirt. This way, if paint does somehow get on my clothing, I have a similar color paint marker that will cover the more obvious paint marks. Yellow paint drips on blue clothes is quite obviouse, even from 20 feet away. I'd rather have more paraphinelia (the marker) on me than paint drips, I don't know about you.
The last thing is, if you have your cans in a bag, make sure you pack them standing upright. If you just throw them in there after painting, your gonna be rattling all the way down the block. If you are stopped by police and they hear that little jingle, it's more than likely your getting searched. That may even hold up in court as probable cause.
Basicly, if you do things the right way, you'll be able to say no. You don't have much say once probable cause steps in. And it's very easy for that to happen. Even if the officer doesn't actually have any, they can just say, "He had a strong scent of marijuana on him" or "He had that 1000 mile stare, his eyes were glossy and red, and appeared to be intoxicated/high/whatever". Things like this actually hold up in court, but are hard to disprove, because it's the arresting officers view of how it happened. And things like the scent of weed on you/your car are temporary, and hard to disprove without directly calling the officer a lyer (trying to accuse an officer of outright lying in court, is NOT the best idea. The judge will flip that around on you quick.)