如何将任何属性注入到我们使用Shell导航的页面中 使用Xamarin 的本机导航很简单,因为您必须实例化页面的类型:
Navigation.PushAsync(new HomeViewPage { x = y });
在 Shell 中只允许我传递字符串值
Shell.Current.GoToAsync($"//home/bottomtab2?name={"Cat"}");
我正在尝试传递一个布尔值,它向我显示以下错误: “'System.String' 类型的对象无法转换为'System.Boolean' 类型。”
Shell.Current.GoToAsync($"//home/bottomtab2?test={true}");
如果你尝试发送多个参数,发送的参数都不起作用,有没有办法同时发送几个?
Shell.Current.GoToAsync($"//home/bottomtab2?name={"Cat"}?test={"Dog"}");