【发布时间】:2011-11-14 03:47:33
【问题描述】:
我无法让 ToggleSwitch 控件显示在我的 Windows Phone 应用程序中。我尝试使用的代码是:
<toolkit:ToggleSwitch Header="ToggleSwitch" Height="111" HorizontalAlignment="Left" Margin="7,397,0,0" Name="toggleSwitch1" VerticalAlignment="Top" Width="456" />
或
<controls:ToggleSwitch Header="Test">
<controls:ToggleSwitch.HeaderTemplate>
<DataTemplate>
<ContentControl Content="{Binding}" Foreground="Red"/>
</DataTemplate>
</controls:ToggleSwitch.HeaderTemplate>
</controls:ToggleSwitch>
这两种方法都不起作用,我不知道为什么。这是我正在使用的 C# 应用程序。
【问题讨论】:
标签: c# xaml windows-phone-7