Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/email/3.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
Windows phone 8.1 组合框项目突出显示xaml windows phone 8.1中的2个项目_Windows Phone 8.1_Winrt Xaml - Fatal编程技术网

Windows phone 8.1 组合框项目突出显示xaml windows phone 8.1中的2个项目

Windows phone 8.1 组合框项目突出显示xaml windows phone 8.1中的2个项目,windows-phone-8.1,winrt-xaml,Windows Phone 8.1,Winrt Xaml,我使用的combobox包含40个项目,这些项目将在弹出按钮中打开,选择一个项目后弹出按钮关闭,如果我尝试选择其他项目,弹出按钮将打开,突出显示2个项目以及一个我未选择的项目。我试着改变一下风格,但对我不起作用 <ComboBox > <ComboBoxItem> <TextBlock Text="One"/> </ComboBoxItem>

我使用的combobox包含40个项目,这些项目将在弹出按钮中打开,选择一个项目后弹出按钮关闭,如果我尝试选择其他项目,弹出按钮将打开,突出显示2个项目以及一个我未选择的项目。我试着改变一下风格,但对我不起作用

 <ComboBox >
                <ComboBoxItem>
                    <TextBlock Text="One"/>
                </ComboBoxItem>
                <ComboBoxItem>
                    <TextBlock Text="Two"/>
                </ComboBoxItem>
                <ComboBoxItem>
                    <TextBlock Text="Three"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Four"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Five"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Six"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Seven"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Eight"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Nine"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Ten"/>
                </ComboBoxItem>
                <ComboBoxItem>
                    <TextBlock Text="Eleven"/>
                </ComboBoxItem>
                <ComboBoxItem>
                    <TextBlock Text="Twelve"/>
                </ComboBoxItem>
                <ComboBoxItem>
                    <TextBlock Text="Thirteen"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Fourteen"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Fifteen"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Sixteen"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Seventeen"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Eighteen"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Nineteen"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Twenty"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="TwentyOne"/>
                </ComboBoxItem>
                <ComboBoxItem>
                    <TextBlock Text="TwentyTwo"/>
                </ComboBoxItem>
                <ComboBoxItem>
                    <TextBlock Text="TwentyThree"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="TwentyFour"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="TwentyFive"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="TwentySix"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="TwentySeven"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="TwentyEight"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="TwentyNine"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Thirty"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="ThirtyOne"/>
                </ComboBoxItem>
                <ComboBoxItem>
                    <TextBlock Text="ThirtyTwo"/>
                </ComboBoxItem>
                <ComboBoxItem>
                    <TextBlock Text="ThirtyThree"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="ThirtyFour"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="ThirtyFive"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="ThirtySix"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="ThirtySeven"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="ThirtyEight"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="ThirtyNine"/>
                </ComboBoxItem>

                <ComboBoxItem>
                    <TextBlock Text="Fourty"/>
                </ComboBoxItem>
            </ComboBox> 


提前感谢:)

问题在于listviewitems的虚拟化(这是控件中的一个bug)。这里讨论了解决这个问题的方法。希望对你有帮助。