A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://learn.microsoft.com/en-us/uwp/api/windows.ui.xaml.controls.contentcontrol.contenttemplate below:

ContentControl.ContentTemplate Property (Windows.UI.Xaml.Controls) - Windows apps

Important

Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Gets or sets the data template that is used to display the content of the ContentControl.

DataTemplate ContentTemplate();

void ContentTemplate(DataTemplate value);
public DataTemplate ContentTemplate { get; set; }
var dataTemplate = contentControl.contentTemplate;
contentControl.contentTemplate = dataTemplate;
Public Property ContentTemplate As DataTemplate
<contentControl>
  <contentControl.ContentTemplate>
    dataTemplate
  </contentControl.ContentTemplate>
</contentControl>
- or -
<contentControl ContentTemplate="templateReference"/>
Property Value

The data template that is used to display the content of the ContentControl.

Remarks

Instead of declaring a fixed DataTemplate, you can also implement a DataTemplateSelector and use it to set the ContentTemplateSelector property. This technique enables custom template switching based on input data, at the application level. For more information, see DataTemplateSelector.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4