Xamarin.forms 如何在CarousePage中一次加载一页

Xamarin.forms 如何在CarousePage中一次加载一页,xamarin.forms,Xamarin.forms,比如说,我在最顶端创建了一个网格(看起来像一个导航栏),其中包含几个按钮:btn1、btn2、btn3、btn4 问题:如何在基于btn单击的转盘页面中一次显示一个页面。Btn1将显示第1页,依此类推。不允许刷卡 下面:我使用插入在外部创建的页面 <CarouselPage xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"

比如说,我在最顶端创建了一个网格(看起来像一个导航栏),其中包含几个按钮:btn1、btn2、btn3、btn4

问题:如何在基于btn单击的转盘页面中一次显示一个页面。Btn1将显示第1页,依此类推。不允许刷卡

下面:我使用插入在外部创建的页面

<CarouselPage 
xmlns="http://xamarin.com/schemas/2014/forms"    
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"       
x:class ="MyApp.MainPage"
xmlns: local ="clr-namespace:myApp"
>

<local:Page1></local:Page1>

<local:Page2></local:Page1>

<local:Page3></local:Page1>


</CarouselPage>


如果不允许刷卡,则不需要旋转木马。例如,使用空视图作为容器,并添加/删除子项(您的视图,而不是页面),如果不允许滑动,则不需要旋转木马。例如,使用空视图作为容器并添加/删除子项(视图,而不是页面)