How to connect sensors, xbee modules and xbee shield to an Arduino board?

Are you talking about programming the xbee modules? Actually what i meant was whether or not there exists a way that you can burn "sketches" on to an arduino board while it has a shield or two mounted over it? Or do i have to take the shield off before i burn the code?
[I apologize for not being able to put the question straight enough...Hope this makes it easier to understand]