I would like to clarify my understanding of your question. What do you mean "stay on surfaces"? Do you mean on doorknobs and things like that?
That is a tough question to answer because it depends on the virus, the surface, the environment. Estimates are that most viruses can live from a few seconds (HIV) to 48 hours. Specifically for the cold viruses (which is what causes pink eye), they can live longer on hard surfaces (like metal, etc.) than soft surfaces. Although one study I read reported viable virus on paper money 2 weeks later.
Of course keep in mind that most infections are spread through contact (with mucus membranes), either coughing, sneezing, tears, saliva, etc.
Hope this helps.