Solucionado (ver solução)
Solucionado
(ver solução)
3
respostas

Erros ao abrir o projeto das aulas

Tento abrir o projeto da aula no vs 2015 e estou tendo os seguintes erros:

Severity Code Description Project File Line Suppression State Error The "XamlCTask" task could not be instantiated from "C:\Users\Gustavo\Desktop\xamarin-crie-aplicacoes-mobile-5755b276c34fa3cf450e4fce0f2d5d9f18223545\packages\Xamarin.Forms.2.3.3.175\build\portable-win+net45+wp80+win81+wpa81+MonoAndroid10+Xamarin.iOS10+xamarinmac20\Xamarin.Forms.Build.Tasks.dll". Could not load file or assembly 'Xamarin.Forms.Build.Tasks, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515) TestDrive.Aula5

Severity Code Description Project File Line Suppression State Error The "XamlCTask" task has been declared or used incorrectly, or failed during construction. Check the spelling of the task name and the assembly name. TestDrive.Aula5

Severity Code Description Project File Line Suppression State Error The "ResolveLibraryProjectImports" task failed unexpectedly. System.IO.FileNotFoundException: Could not load assembly 'TestDrive, Version=0.0.0.0, Culture=neutral, PublicKeyToken='. Perhaps it doesn't exist in the Mono for Android profile? File name: 'TestDrive.dll' at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.Resolve(AssemblyNameReference reference, ReaderParameters parameters) at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.Resolve(String fullName, ReaderParameters parameters) at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.Resolve(String fullName) at Java.Interop.Tools.Cecil.DirectoryAssemblyResolver.GetAssembly(String fileName) at Xamarin.Android.Tasks.ResolveLibraryProjectImports.Extract(DirectoryAssemblyResolver res, ICollection1 jars, ICollection1 resolvedResourceDirectories, ICollection1 resolvedAssetDirectories, ICollection1 resolvedEnvironments) at Xamarin.Android.Tasks.ResolveLibraryProjectImports.Execute() at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute() at Microsoft.Build.BackEnd.TaskBuilder.d__26.MoveNext() TestDrive.Droid

3 respostas

Olá, Gustavo!

Por favor siga estes passos:

  1. Feche a solução, feche o Visual Studio

  2. Apague o conteúdo da pasta Packages (todas as DLLs referenciadas pelo NuGet)

  3. Apague a pasta: C:\Users{USER}\AppData\Local\Microsoft\VisualStudio\14.0\ComponentModelCache

  4. Abra a solução novamente

  5. Faça o build (isso irá fazer com que o Nuget obtenha todas as DLLs novamente baseado no packages.config)

Por favor nos avise se funcionou. Esperamos que você goste do curso!

Boa sorte e bons estudos!

solução!

Eu resolvi atualizando apenas o Xamarin.Forms ao invés de atualizar todas as dependências em conjunto com o Xamarin.Forms. Funcionou pra mim aqui.

Excelente, Gustavo, fico feliz que tenha conseguido!