How to fix these errors. (Top figure)

BenTam 1,561 Reputation points
2023-09-02T05:19:23.02+00:00

Dear All,

How to fix these errors.

Error

Files in the folder C:\Users\Ben Tam\source\repos\NewTims\BaseControlLibrary\obj\Debug

FileExplorer2

The content of the file ".NETFramework,Version=v4.0.AssemblyAttributes.cs" (in the red lines in the File Explorer).

Version4

Files in folder "C:\Users\Ben Tam\source\repos\NewTims\obj\Debug\net7.0-windows" (in the red lines in the File Explorer).

FileExplorer1

The content the file "C:\Users\Ben Tam\source\repos\NewTims\obj\Debug\net7.0-windows".

Version7

The Solution Explorer of the solution.

SolutionExplorer

C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,274 questions
{count} votes

Accepted answer
  1. Jiale Xue - MSFT 33,686 Reputation points Microsoft Vendor
    2023-09-04T08:49:20.7366667+00:00

    Hi @BenTam-3003 , Welcome to Microsoft Q&A,

    As the wrong word says.

    They are duplicates. Select a file to annotate its contents, or delete it.

    For details, you can check this case, which is similar to your error:https://learn.microsoft.com/en-us/answers/questions/1349370/why-am-i-getting-these-errors

    Best Regards,

    Jiale


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment". 

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


1 additional answer

Sort by: Most helpful
  1. Bruce (SqlWork.com) 56,686 Reputation points
    2023-09-04T15:50:21.03+00:00

    A .net 7 project can not reference a 4.* project due to differences in the runtimes.

    0 comments No comments