Windows phone 8.1 WP8.1的SDK中是否有弹出类?

Windows phone 8.1 WP8.1的SDK中是否有弹出类?,windows-phone-8.1,Windows Phone 8.1,Windows Phone 8.1的SDK中是否有弹出类(或类似类) System.Windows.Controls.Primitives.Popup不存在,因为System.Windows.Controls.不可用 当然,MessageDialog和PopupMenu是可用的,但它们似乎都没有默认的行为,即不带按钮(甚至可能是非模态的)可撤销信息 必须使用自定义用户控件吗?在Windows phone中,RT Popup类是“Windows.UI.Xaml.Controls.Primitive

Windows Phone 8.1的SDK中是否有弹出类(或类似类)

System.Windows.Controls.Primitives.Popup不存在,因为
System.Windows.Controls.
不可用

当然,MessageDialog和PopupMenu是可用的,但它们似乎都没有默认的行为,即不带按钮(甚至可能是非模态的)可撤销信息


必须使用自定义用户控件吗?

在Windows phone中,RT Popup类是“Windows.UI.Xaml.Controls.Primitives”命名空间的成员。您可以在xaml中定义弹出窗口,如下所示:

 <Popup x:Name="ppup" IsOpen="False" Grid.Row="2" >
            <StackPanel Background="Blue" Height="100" Width="400">
                <TextBlock Text="This is Pop up control of Xaml" FontSize="20" FontWeight="Bold">
                </TextBlock>
            </StackPanel>
        </Popup>


在代码隐藏中,您可以将IsOpen属性设置为true/false。

非常好,谢谢。在编程方面,我找不到它,所以
Windows.UI.Xaml.Controls.Primitives.Popup
非常合适。