Sending Grid Content Through a ContentControl

njsokalski

Well-known member
Joined
Mar 16, 2011
Messages
102
Programming Experience
5-10
I have a Windows Phone 7 app that has a ContentControl that I want to use to fill in some of the cells in a Grid in the ContentControl's ContentPresenter in the ControlTemplate. The ControlTemplate already has the Grid, as well as some of the elements I want in it, I want to use the ContentControl to specify the rest. However, this means passing multiple elements in the Content property, which gives an error. I thought about placing the elements inside a Panel (or some other container) and then programmatically extracting the elements, but that seems kind of inefficient. Basically, I want it to take the elements between the opening and closing tags (the Content) and place them where the ContentPresenter is. Is there any efficient way to do this? Thanks.
 
Back
Top