Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/wpf/12.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/typo3/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
WPF对单选按钮使用触摸键_Wpf_Radio Button_Touch - Fatal编程技术网

WPF对单选按钮使用触摸键

WPF对单选按钮使用触摸键,wpf,radio-button,touch,Wpf,Radio Button,Touch,我在参数视图的WPF/C上使用RadioButton。我希望用户只选择1个选项,所以我使用RadioButton和GroupName。它工作正常,但它只对点击事件做出反应,而不是触摸 有没有办法让触控事件控制我的按钮,或者我必须用触控事件重新定义RadioButton的所有默认组件 这是我的单选按钮,即使我不认为它们对我的问题有用 <Viewbox Height="50"> <RadioButton x:Name="imposerOrdreHaut" Content="

我在参数视图的WPF/C上使用RadioButton。我希望用户只选择1个选项,所以我使用RadioButton和GroupName。它工作正常,但它只对点击事件做出反应,而不是触摸

有没有办法让触控事件控制我的按钮,或者我必须用触控事件重新定义RadioButton的所有默认组件

这是我的单选按钮,即使我不认为它们对我的问题有用

<Viewbox Height="50">
    <RadioButton x:Name="imposerOrdreHaut" Content="Avec" IsChecked="True" GroupName="ordre" Padding="2"  Checked="RadioButtonChecked" />
</Viewbox>
<Viewbox Height="50">
    <RadioButton  Content="Sans" GroupName="ordre" Padding="2" Checked="RadioButtonChecked" />

最后,我使用了一个触地事件who switch IsChecked=true,它会自动切换false其他按钮