All Questions
Tagged with asp.net-core .net-6.0
941
questions
0
votes
0
answers
24
views
In one of the cshtml files,namespaces can not be found
I am using visual studio 2022 .net 6. All the other cshtml files within the same project are not showing any issues. Only in one cshtml file, the namespaces are not able to be found. All the ...
0
votes
0
answers
37
views
Microsoft.AspNetCore.Server.Kestrel.Core vulnerability issue - fix
what is the latest version of "Microsoft.AspNetCore.Server.Kestrel.Core" in the series of 6 like Version="6. * . *" In nuget gallery it is not available any thing later than v2.2.0
...
0
votes
1
answer
36
views
How to create a custom object from a register page
I want to create a Department object that doesn't exist yet an assign it a AppUser along side a Person object then add it to database during the registration process with .net 6.0 ef identity ...
1
vote
1
answer
39
views
How to insert a custom object into an User using foreign key
I'm currently having problem with displaying a custom object property because the program doesn't seem to insert the associated value from the table with appropriate foreign key.
Here are the codes
...
0
votes
1
answer
38
views
How to use razor renderer in .NET 6?
In my .NET 4.8 Web API application, I take an externally received HTML formatted string and convert it to a .cshtml file using Razor Engine, then append it to my page with JavaScript. I do this using ...
0
votes
0
answers
56
views
Found multiple publish output files with the same relative path. while publising ASP.NET Core 6 project
In .NET Core 6 where when publishing with Web Deploy via Visual Studio 2022, I get the following error:
Error: found multiple publish output files with the same relative path:
There is no issues ...
1
vote
1
answer
60
views
Is it possible to use ProtectedLocalStorage without regular .NET Core?
Seems like an obvious upgrade from regular localstorage, but I've only seen it used with Blazor.
I'm using ASP.NET Core 6.0 MVC.
Should I just put this in my program.cs?
builder.Services.AddScoped<...
1
vote
1
answer
45
views
Unexpected System.BadImageFormatException: Index not found That is Fixed with Restart
I have an ASP.NET Core 6 MVC web application hosted on IIS that all of a sudden started throwing the following exception:
System.Reflection.ReflectionTypeLoadException: Unable to load one or more of ...
0
votes
0
answers
55
views
.NET 6 upgrade to .NET 8 using OIDC is now throwing error: "An invalid request URI was provided."
I have a fairly standard .NET 6 app that is using cookies for DefaultScheme and OIDC for the challenge scheme. I didn't change the registrations for either, I simply upgraded from .NET 6 to .NET 8.
I'...
0
votes
1
answer
65
views
Is It Possible To Launch 2 Browser Tabs With Different Urls When Debugging in Visual Studio 2022?
I have a .NET 6 web API project that uses Hangfire in the background. When I debug the project from VS2022 I would like to open both the swagger UI and the Hangfire dashboard in separate tabs when the ...
1
vote
1
answer
55
views
Request Body mixed together when getting successive requests in ActionFilter C# .Net 6.0
We have a custom action filter that does XSD validation on request bodies to ensure that the XML is validated before the controller action is hit. We created an extension method to read the payload ...
4
votes
3
answers
685
views
Blazor (WA .NET6)- TS1109 Error, how to fix it?
I've been working on a Blazor WebAssembly .NET6 project for a couple of years.
I updated VS2022 recently to the latest 17.10.0(I was in the previous 16.9 before), and after that I'm having TS1109 all ...
0
votes
1
answer
56
views
Error in IIS while publishing app locally, Entity Framework Core migrations do not work
As you see there is a command on "Entity Framework Migrations" which shows an error message:
dotnet ef dbcontext list --json
More than one project was found in the current working ...
0
votes
1
answer
33
views
How to Get Microsoft .NET SDK 6.0 in the msix format
I am doing this on a non-admin user and I am trying to get .NET 6.0 Sdk as MSIX.
I tried dotnet-install script but nothing worked. And when I ran dotnet --list-sdks but there was none. There were only ...
0
votes
1
answer
65
views
How can my web api decrypt a password, that was prevously encrypted in a console application, using DPAPI?
I have to store user credentials in a web api somewhere. I decided I create a console application in the solution, next to the Web API, that encrypts the data, and writes it to the web api's ...