Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

289
Visualizações
Split Asp.Net Core Single Project App into multiple projects - The type conflicts with the imported type in xxx Using the type defined in xxx

I have been splitting my single project Asp.net Core app into different projects and I am seeing some strange errors and warnings and think maybe I have done it wrong. The main warning is that all through my files I have:

The type 'VepoContext' in '/Users/benjaminfarquhar/dev/vepo_back_end/Vepo/Vepo.Data/VepoContext.cs' conflicts with the imported type 'VepoContext' in 'Vepo.Data, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'. Using the type defined in '/Users/benjaminfarquhar/dev/vepo_back_end/Vepo/Vepo.Data/VepoContext.cs'. [Vepo, Vepo]csharp(CS0436)

On most of my custom Classes.

I'm also getting:

Duplicate 'global::System.Runtime.Versioning.TargetFrameworkAttribute' attribute [Vepo]

For which I have applied a few of the widely accepted Stack Overflow fixes, which have not worked.

This is my project structure. The project named "Vepo" is the Asp.net Core app and the other projects, Vepo.Data, Vepo.Domain, and Vepo.Common are all Class Library projects. I am wondering if I have placed my data, domain, and common projects inside the Asp.net Core project as it looks like that is the case in VS Code but not in Visual Studio:

In Visual Studio: enter image description here

In VS Code:

enter image description here

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

Yes, you have placed your secondary projects inside the actual Vepo project. However, you also have the ones outside of the main project. Make sure to remove the ones inside the main since those are what are most likely causing you to get an error where two of the same types are loaded.

over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda