Build failed, c:..NT.csproj(3717,3): errorMSB4019: imported project was not found for .NET6.0

Below is the Error i am getting while scanning my dotnet project solution in sonarqube , actually there is not visual studio folder inside "C:
\Program Files\dotnet\sdk\7.0.201\Microsoft\VisualStudio.… as mentioned in the error can you suggest some solution how to configure this and scan the project .

stacktrace is as below:-

Microsoft Windows [Version 10.0.19044.3086]
(c) Microsoft Corporation. All rights reserved.

C:\eTrack Main\eTrackClient26july2023>dotnet sonarscanner begin /k:"client-portal" /d:sonar.host.url="http://localhost:9000"  /d:sonar.login="sqp_e7ec214ec13708ccf66f24474d55675a6bc8c564"
SonarScanner for MSBuild 5.13
Using the .NET Core version of the Scanner for MSBuild
Pre-processing started.
Preparing working directories...
17:33:00.418  Updating build integration targets...
17:33:00.555  Fetching analysis configuration settings...
17:33:00.867  Provisioning analyzer assemblies for cs...
17:33:00.869  Installing required Roslyn analyzers...
17:33:00.87  Processing plugin: csharp version 8.40.0.48530
17:33:00.908  Processing plugin: vbnet version 8.40.0.48530
17:33:01.051  Provisioning analyzer assemblies for vbnet...
17:33:01.052  Installing required Roslyn analyzers...
17:33:01.053  Processing plugin: csharp version 8.40.0.48530
17:33:01.054  Processing plugin: vbnet version 8.40.0.48530
17:33:01.062  Incremental PR analysis is available starting with SonarQube 9.9 or later.
17:33:01.064  Cache data is empty. A full analysis will be performed.
17:33:01.088  Pre-processing succeeded.

C:\eTrack Main\eTrackClient26july2023>dotnet build
MSBuild version 17.5.0-preview-23061-01+040e2a90e for .NET
  Determining projects to restore...
  Nothing to do. None of the projects specified contain packages to restore.
C:\eTrack Main\eTrackClient26july2023\ETRACKCLIENT\ETRACKCLIENT.csproj(3717,3): error MSB4019: The imported project "C:
\Program Files\dotnet\sdk\7.0.201\Microsoft\VisualStudio\v17.0\WebApplications\Microsoft.WebApplication.targets" was no
t found. Confirm that the expression in the Import declaration "C:\Program Files\dotnet\sdk\7.0.201\Microsoft\VisualStu
dio\v17.0\WebApplications\Microsoft.WebApplication.targets" is correct, and that the file exists on disk.

Build FAILED.

C:\eTrack Main\eTrackClient26july2023\ETRACKCLIENT\ETRACKCLIENT.csproj(3717,3): error MSB4019: The imported project "C:
\Program Files\dotnet\sdk\7.0.201\Microsoft\VisualStudio\v17.0\WebApplications\Microsoft.WebApplication.targets" was no
t found. Confirm that the expression in the Import declaration "C:\Program Files\dotnet\sdk\7.0.201\Microsoft\VisualStu
dio\v17.0\WebApplications\Microsoft.WebApplication.targets" is correct, and that the file exists on disk.
    0 Warning(s)
    1 Error(s)

Time Elapsed 00:00:00.59

Hi,

Welcome to the community!

From your log, what failed was the build itself, not the analysis:

 
Ann