This blog post has a nice code which dumps the visual tree in the immediate window. Check it out.

http://blog.thekieners.com/2009/11/07/silverlight-visual-tree-visualizer/