** The value of this parameter needs to be specified through a binding in most cases. This requires some additional setup when used in combination with KeyValueList, see examples below.
== Examples Example ==
This example demonstrates a simple view where we display some information about a property in a custom view. A close button is also included. We assume:
* A "FINISHED" property exists on the object;
...
xmlns:controls="using:UBIK.WinX.Controls"
x:Name="SomeButtonSomeRandomButton"
DataContext="{Binding}"
Command="{Binding DisplayViewCommand}">
<controls:KeyValueList>
<controls:KeyValueParameter Key="TemplateName" Value="SomeRandomView" />
<controls:KeyValueParameter Key="TemplateDataContext" Value="{Binding DataContext.Properties.AllItems[FINISHED].Content, ElementName=SomeButtonSomeRandomButton}" />
</controls:KeyValueList>
</Button.CommandParameters>
...
xmlns:classes="clr-namespace:UBIK.CPL.Classes;assembly=UBIK.CPL"
x:Name="SomeButtonSomeRandomButton"
BindingContext="{Binding}"
Command="{Binding DisplayViewCommand}">
For the example code shown above, the following content should be placed inside a custom view named SomeRandomView.xaml (UWP) or SomeRandomView.xamlx (Xamarin).
<source lang = "xml">
<SomeTextControlSomeTypeOfTextControl
...
Text="{Binding KeyValueList[TemplateDataContext].Value}" />