I'm trying to access a user control which is inside the control template of a content control. Specifically:
<ContentControl x:Name="MyList" >
<ContentControl.Template>
<ControlTemplate x:Name="MyControlTemplate">
<Border RenderTransformOrigin="0,0" x:Name="border">
<UserControls:MyControl x:Name="MyControlName" Width="100" ViewModel="{Binding}" />
I can access this.MyList but it says this.MyControlName is not found. How do I access the MyControlName object from code-behind in this situation?
Thanks!