gpt4 book ai didi

Xamarin 表格 : Single button that opens a dropdown menu

转载 作者:行者123 更新时间:2023-12-05 06:35:43 31 4
gpt4 key购买 nike

嗨,有人知道我是否可以在 Xamarin Forms 中创建一个按钮来打开一个小的下拉菜单吗?我在 android studio 中完成了此操作,但找不到在 Xamarin 中如何工作的方法。

它应该是这样的:

It should look like this

如果按钮被点击,就像这样:

And like this if the button is clicked

并且该按钮不应位于导航栏中,因为该页面没有导航栏。

因此,如果有人能帮助我,我将非常感激并为我的糟糕英语感到抱歉。

最佳答案

Xamarin 中最接近的 API 是 display a pop-up使用 DisplayActionSheet,但下拉菜单将位于屏幕底部。或者您可以使用 Picker ( link to documentation )。

如果您想实现与帖子中的图片完全一样的东西,您可以创建一个包含几个按钮的 StackLayout,并在单击下拉菜单按钮时显示它。

关于Xamarin 表格 : Single button that opens a dropdown menu,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49555660/

31 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com