开发者

How do I select a template for a GroupBox based on the value of an object

I want the contents of a group box to be selected by value, so how I do write the XAML to do this?

<GroupBox Header="Specific details"
    ContentTemplateSelector={StaticResource 开发者_开发问答someSelector}>

...

</GroupBox>

The template selector will let me select which template to use, but what I can't figure is the syntax to associate this group box with a value in a variable somehow?


The answer is to use a TabControl with no headers and let the SelectedIndex be set by the value.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜