Selecting the objects

I want to select some objects in a 3d space and color them. But i don’t know that how can i select them and find the index of the selected object. Some books have some suggestion about the selection buffer. but those information aren’t sufficient. here’s my exact question:
I have a sphere and a cone. I want to select one of these objects and add a color to it. So how can i do this?

Hi Ehsan,

well there are many posts about this question. Selection and feedback modes should help you right.

Try to make a search on these forums, I’m pretty sure you’ll find out what you want.

I can’t say more as I never made such things.