问题描述
我尝试为拖放添加事件,但我仍然收到此消息:
Could not resolve type with token 0100004d from typeref (expected class 'Xamarin.Forms.DropGestureRecognizer' in assembly 'Xamarin.Forms.Core,Version=2.0.0.0,Culture=neutral,PublicKeyToken=null')'
我正在使用Nuget软件包。
是否有要添加的扩展名?
这是使用的代码。
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:d="http://xamarin.com/schemas/2014/forms/design"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
xmlns:local="clr-namespace:SafeMountain"
x:Class="SafeMountain.MainPage"
xmlns:control="clr-namespace:SafeMountain.UserControls"
NavigationPage.HasNavigationBar="False">
<Grid x:Name="gridMain">
<StackLayout Orientation="Vertical" VerticalOptions="FillAndExpand">
<ScrollView Orientation="Vertical">
<StackLayout Margin="15,15,0" x:Name="slItems">
<StackLayout.GestureRecognizers>
<DropGestureRecognizer AllowDrop="True" Drop="DropGestureRecognizer_Drop"/>
</StackLayout.GestureRecognizers>
<Label x:Name="lblLastPosCatch" HorizontalOptions="Center" HorizontalTextAlignment="Center" TextColor="LightGray" FontSize="Micro"/>
<StackLayout x:Name="slDeconnexion">
<Label x:Name="lblDeconnexionInfo" TextColor="Red" Text="Déconnecté du réseau cellulaire" HorizontalTextAlignment="Center"/>
</StackLayout>
</StackLayout>
</ScrollView>
</StackLayout>
</Grid>
</ContentPage>
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)