2017-08-09 5 views
0

私はXamarinは私が2つのエラーを取得していますがカルーセルビューカルーセルビューXamarinフォームが2つのエラー

フォームNugetからインストールを与える「Xamarin.Forms.CarouselView、バージョン= 0.0.0.0、Culture = neutral、PublicKeyToken = null '

2)「ResolveLibraryProjectImports」タスクが予期せず失敗しました。 System.IO.FileNotFoundException:アセンブリ 'MashamApp、Version = 0.0.0.0、Culture = neutral、PublicKeyToken ='を読み込めませんでした。おそらく、Android用プロファイルのMonoには存在しないでしょうか?あなたが正常に見えるので、私は、任意のコードの変更をお勧めすることはできません

<ContentPage xmlns="http://xamarin.com/schemas/2014/forms" 
     xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"    
     xmlns:control="clr-namespace:Xamarin.Forms;assembly=Xamarin.Forms.CarouselView" 
     x:Class="MashamApp.MainPage" BackgroundColor="#ff1b74bb"> 

<Grid x:Name="gMain" BackgroundColor="#ffebf6ff"> 

    <Grid.RowDefinitions> 
     <RowDefinition Height="1*"></RowDefinition> 
     <RowDefinition Height="1*"></RowDefinition> 
     <RowDefinition Height="1*"></RowDefinition> 
     <RowDefinition Height="1*"></RowDefinition> 
    </Grid.RowDefinitions> 

    <Grid Grid.Row="0"> 
     <Label x:Name="lblName" HorizontalTextAlignment="Center" VerticalTextAlignment="Center" FontSize="Medium" TextColor="White"></Label> 
    </Grid> 

    <Grid Grid.Row="1"> 
     <control:CarouselView ItemsSource="{Binding MyDataSource}"> 
      <control:CarouselView.ItemTemplate> 
       <DataTemplate> 
        <Label Text="{Binding LabelText}" /> 
       </DataTemplate> 
      </control:CarouselView.ItemTemplate> 
     </control:CarouselView> 
    </Grid> 
+0

あなたはすべてのプロジェクトにNuGetパッケージをインストールしました。すなわち共有プロジェクトとAndroidプロジェクト –

答えて

0

は、しかしXamarin.Forms.CarouselView、バージョン= 0.0.0.0、ニュートラル文化=、なPublicKeyToken = nullは私には少し容疑者を探します。私がお勧めすることは多分NUで、すべてのパッケージを再インストールしてみてください、あなたが(プロジェクトに参照することによって何の黄色い三角形)を正常に動作していないすべての あなたの参照を持っていることを確認作っているパッケージマネージャコンソールコマンドに

Update-Package 

を取得することもできますこれを1つのプロジェクトに限定します。

Update-Package -Project YourProjectName 

以前にインストールしたのと同じバージョンにパッケージを再インストールする場合は、Update-Packageコマンドで-reinstall引数を使用できます。

Update-Package -reinstall 

私はこの回答をHow do I get NuGet to install/update all the packages in the packages.config?から取りました。

希望すると便利です。私に知らせていない場合、私は答えを取り除きます(私は50人未満のコメントをすることはできないので、答えを使用しなければなりませんでした)乾杯!うまく

+0

OKこれは明らかに、これは彼らがクラスの名前を変更する答えではありません。 –

0

、appearnly彼らは、コードは次のようになりことshuold名前空間の名前とcontrollの名前を変更します。

<ContentPage xmlns="http://xamarin.com/schemas/2014/forms" 
     xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"    
     xmlns:c="clr-namespace:CarouselView.FormsPlugin.Abstractions;assembly=CarouselView.FormsPlugin.Abstractions" 
     x:Class="MashamApp.MainPage" BackgroundColor="#ff1b74bb"> 

<Grid x:Name="gMain" BackgroundColor="#ffebf6ff"> 

    <Grid.RowDefinitions> 
     <RowDefinition Height="1*"></RowDefinition> 
     <RowDefinition Height="1*"></RowDefinition> 
     <RowDefinition Height="1*"></RowDefinition> 
     <RowDefinition Height="1*"></RowDefinition> 
    </Grid.RowDefinitions> 

    <Grid Grid.Row="0"> 
     <Label x:Name="lblName" HorizontalTextAlignment="Center" VerticalTextAlignment="Center" FontSize="Medium" TextColor="White"></Label> 
    </Grid> 

    <Grid Grid.Row="1"> 
     <c:CarouselViewControl x:Name="CaruselViewCon" ItemsSource="{Binding MyDataSource}"> 
      <c:CarouselViewControl.ItemTemplate> 
       <DataTemplate> 
        <Image Source="{Binding LabelText}" TextColor="Black" /> 
       </DataTemplate> 
      </c:CarouselViewControl.ItemTemplate> 
     </c:CarouselViewControl> 
    </Grid> 

関連する問題