15,205
questions
1
vote
0
answers
15
views
Is local dependency resolution possible in .NET without NuGet?
I have two shared library .NET projects, B and C, which depend both on another shared library project, D.
Both B and C have respective CLI wrapper projects which they need to build independently with, ...
0
votes
0
answers
22
views
How VS knows that it is replacing a nuget package when I don't reference one
My setup - VS2019, FW-style project, FW 4.7.2. Project is set to use <PackageReference ... (vs packages.config)
Look at the picture. I don't have System.Runtime.CompilerServices.Unsafe.4.6.0 ...
-1
votes
0
answers
24
views
how to configure 3rd party .obj and .lib files in the C# project(.csproj) to build and link using the MSBUILD
I have a C# project file which contain all the files(.cs files) it required to build the application. But, we need to link with a 3rd party .obj and .lib file during the build.
Any suggestion how to ...
0
votes
0
answers
21
views
How to Convert OWIN-Based ASP.NET Application to SDK-Style Project?
I am in the process of converting an OWIN-based ASP.NET application targeting .NET Framework 4.7.2 to the new SDK-style project format. For this, I am using the Microsoft.NET.Sdk.Web SDK.
I have a ...
-1
votes
1
answer
46
views
How do I create a TypeScript project for NodeJS in Visual Studio 2022 (non-code)
I want to develop a nodeJS script in a Visual Studio 2022 (not Visual Studio Code) project.
I have a ASP.NET Core C# project.
In that project, i have a folder TypeScript.
In the typescript i have ...
0
votes
0
answers
32
views
Generate self-contained, single file. exe with Roslyn?
Is it possible to generate a self-contained, single file .exe with Roslyn?
I wouldn't like to rely on dotnet or MS Build.
0
votes
0
answers
25
views
Unresolved symbol: different behavior in QMake and MSBuild
I have three projects: A, B, and C. Project A is an executable/DLL, and projects B and C are static libraries. There is a function Add(int, int) in B, which is called by A. The implementation of Add ...
1
vote
1
answer
53
views
MSBuild - csproj - Use combinations to exclude folder from build
In order to allow building our projects in Visual Studio and a Linux DevContainer side-by-side, I changed the build configuration of our project as follows:
Directory.Build.props
<Project>
<...
0
votes
0
answers
45
views
Can I set Severity level of CS0535 in C# to suggested
My Problem is, that in my cleanUp is the fix warning/erros from editorconfig. But it also auto fixes the CS0535. But I don't want that to happen. How can I silent the error and get the fix as a ...
0
votes
1
answer
26
views
Is there any way to detect specific errors in a .NET csproj build, and log a particular error message in response
Every now and then I come across a weird build error, with a simple but highly unintuitive fix.
Generally when something somewhere has been configured to do something ugly :D
Obviously I fix it "...
1
vote
1
answer
49
views
MSBuild fails when referencing sys tables in a different database
SQL Server 2019. We have a purchased application and can't add any code to that database (let's call it vendor). We have a view in another database (call it xyz) that is getting data from the sys ...
1
vote
2
answers
94
views
How to enable code analysis IDE0058 as a build error?
I want to enable IDE0058 as an error during build. Here's how I attempted to do that.
Start Visual Studio 2022 (Version 17.11.2)
Create new project. Project type: C#, Windows, Console -> Console ...
0
votes
1
answer
115
views
Azure Devops can an ASP.NET Core 8 Web API be built with .NET Framework references?
I have an ASP.NET Core 8 Web API that I am building/deploying through Azure Devops. The API is being hosted in IIS on a server, so I was using the DotNetCoreCLI@2 task to perform a dotnet publish ...
0
votes
0
answers
12
views
App.Config not found when packaging single project console app as an executable using MSBuild 'package' target
When Running a console app packaged to a single .exe with msbuild I appear to be unable to access my app.config resulting in the binding redirect errors similar to
LOG: This bind starts in default ...
0
votes
0
answers
16
views
Why The Primary Reference Is Copied to Bin
I have a .net SDK Style project, and it adds a PackageReference for System.Configuration.ConfigurationManager with version 4.7.0, and I used MSBuild to build this project, in the build log I see a ...