Most voted "asp.net-core" questions
ASP.NET Core is a Microsoft framework as a redesign of ASP.NET.
Learn more…663 questions
Sort by count of
-
0
votes1
answer62
viewsError searching for record with Firstordefaultasync ASP . NET CORE 3.0
I have a method to search the client in the database by the number of the CPF (no points, only the numbers), but in the database the type is as VARCHAR. I did some tests by POSTMAN to test the API…
-
0
votes1
answer542
viewsUpload/Download large files with ASP.NET Core 2.2
I need to upload and downlods files above 2GB using ASP.NET Core 2.2, but I don’t know the best way to do this. For the download, to using the following method: [HttpGet("id")] public IActionResult…
-
0
votes1
answer43
viewsAsp.Net - Read Files
Hello, I need your help again. I’m working on a project that consists of reading XML files and storing the data in a table. I can already do that, but I have a problem. This is an example of an XML…
-
0
votes1
answer33
viewsHow to create a Controller for the Applicationuser
Good Afternoon, I’m trying to create an administrator area to manage the database accounts, but I’m having difficulties, I have the Applicationuser class and the Loginviewmodel class: public class…
-
0
votes1
answer43
viewsI’m not getting to import a namespace that I created
Goodnight, I created a namespace called: Enums inside Models, when I try to import within a class the Enums, I’m not getting through... I’m with using Entity FrameWork with Asp.Net core MVC Folder…
-
0
votes1
answer190
viewsAccess a Singleton Repository outside the Controller (Dependency Injection)
I have a Repository instance added as Scoped in Startup and to access the instance I do the dependency injection by the Controller constructor, or by Fromservices. However, I need to access…
c# asp.net-mvc asp.net-core asp.net-web-api dependency-injectionasked 4 years, 4 months ago Jd3 Tecnologia 50 -
0
votes1
answer53
viewsDelete key composed of a table with angular and Asp.net core
You guys all clear? next I’m having problems with composite key in my project and I wanted your help because I’m still not quite sure about it, I’m doing the front in Angular and the backend with…
-
0
votes0
answers95
viewsIs it possible to upload blazor webassembly applications with . net core hosted on Herokuapp via Docker?
When I go up a blazor server application, I use the following steps: I create a dockerfile file in the same folder where the project is so: FROM mcr.microsoft.com/dotnet/core/aspnet:3.1-buster-slim…
-
0
votes2
answers40
viewsHow to do JSON function return Monthly amount of liters fueled in one year period
The function should return this Example: { "January": 500.00, "February": 514.00, ....} My table has the following fields. Km of supply Liters Abastecidos Valor Pago Date of supply I developed an…
-
0
votes1
answer32
viewsHow to avoid using Service Locator in my Unit Of Work with Delimited Contexts and Mediatr?
Hello, I am starting studies on Ddds and delimited contexts and would like to avoid the use of Service Locator to access my repositories through the Unit of Work. I am currently using Mediatr to…
-
0
votes1
answer14
viewsPublish Core Web Application with Authentication in Azure
I created a Core Web Application , with Visual Studio 2019 and published it following exactly the step by step indicated in…
-
0
votes0
answers27
viewsHow to cascade a multiselect list based on selecting a Dropbox with Asp.net core Razor
I need help to create a dynamic control. I’m a beginner so... Problem: The page has a selectlist which shows the records of the Jobs table returning the Jobid in the post. I need to capture the id…
-
0
votes0
answers21
viewsSSO using Identity single login for various applications accessing the same database
Hi, hello, introduction: I have been trying to understand, I believe that the functionality of cookies may be the best alternative to help my need to log into only one web page and redirect to…
asp.net-core asp.net-web-api cookies asp.net-identity thatasked 4 years, 1 month ago Guilherme Ferreira 1 -
0
votes1
answer249
viewsConsume Web-Service via WCF with digital certificate
I am developing an application that needs to use a Webservice (WSDL) from a third party company. To access this WSDL I need to use a certificate.pfx. I have already installed this certificate on my…
-
0
votes0
answers19
viewsMultiple Dropdownlist
After doing a lot of research in the documentation and checking right here at Stackoverflow, I decided to ask. My question is the following I created two Dropdownlists. View as it is now:…
-
0
votes0
answers28
viewsRefer to a table in another database on the same server
I’m making an app on C# and .NET Core (ASP.NET Core MVC) using the EntityFrameworkCore and in the Connection String access to a database, say DB1, and I can read the tables in this database…
-
0
votes0
answers40
viewsProblems serializing a form and making a Viewmodel Post using Ajax - Asp.net Core MVC
I’m making a Submit using AJAX, but I’m having problems because it’s giving error 404 and I’ve tried to do several ways to use JSON.stringfy, use [Frombody] in the controller action, etc. Can anyone…
-
0
votes1
answer127
viewsImplementing an API for a website’s business rules: is it an exaggeration? Or is it good practice?
In some places that I worked with C# MVC I saw two ways to program the business model of a web system, being them: coding inside the Controller of the web application; creating a web API Rest and…
-
0
votes1
answer233
viewsQuery user in Sql server
As I do to return instead of a query through a fixed user, the code was in the database to query the users and return it. I use Sql Server with aspnet core 3.1 application Someone who can help me in…
-
0
votes0
answers24
viewsUnilateral Relationship EF sql Server
I have a problem in the relationship of entities with the Entity Framework Core v3.1.5, Code First I have entity Cliente relating to the entity DadosProfissional and my problem is, when I register a…
sql-server asp.net-core asp.net-web-api entity-framework-coreasked 3 years, 11 months ago Ricardo Soares 29 -
0
votes1
answer37
viewsASPNET Core - Error 500 when posting a method that returns a Partialview with only one object
I have a method in my controller called ListagemTarefasEmDesenvolvimento() that returns me a PartialView. However, when I call this method via ajax, the server gives me a status error 500. Below is…
-
0
votes1
answer43
viewsHow to reuse an Enum on other screens containing some different properties
I’m working with a screen "Financial" and another screen "Financial Report". For the Financial screen, I created an Enum with the options "Accounts Payable and Receivables". public enum…
-
0
votes0
answers12
viewsNameandidprovider does not find reference in the class context - ASP.NET Core MVC
I need to do a custom implementation for the input field, so I created the following class: [HtmlTargetElement("input", Attributes = "tm-for", TagStructure = TagStructure.WithoutEndTag)] public…
-
0
votes1
answer75
viewsProblem using Identity in API ASP . NET Core
Good afternoon, I’m trying to use Identity in my API, but I have some error that I believe is dependency injection. I made all the necessary configuration, connected with the bank, managed the…
-
0
votes1
answer20
viewsAppsettings session is not read when running on Docker Container
Refer to Docker-Compose reading of Appsettings. When I run through Docker-Compose, I can’t load the file appsettings. That’s why, only when run by Docker-Compose it does not find the Appsettings…
-
0
votes0
answers35
viewsHow to use a modal bootstrap with dynamic text in an ASP.NET Core application without MVC
I would like to use a modal bootstrap in an ASP.NET Core application without MVC (non-MVC), where the text displayed in the modal-body section is dynamic (Actually, I’m looking for a user-friendly…
-
0
votes0
answers19
viewsMultiple requests for an API result in 500 Internal Server error
I have an API that makes two requests on Microsoft services (POST and GET) that receive a code and bring some information about employees. public async Task<string> AdquirirEmail(string…
-
0
votes0
answers38
viewsError calling localhost API in . Net Core and React Native. Returns (Network Request File) error
I’m trying to connect a request from my app using React Native calling this Api that was made on Dot Net Core. This is the desired result. But when access Android Virtual Device returns me an error…
-
0
votes1
answer111
viewsHow to access a global application.json variable in . NET Core c#
I am new with programming and I’m having difficulty accessing a Token that is as variable in the file application.json. It is a console application, the goal is only to use the token of the global…
-
0
votes0
answers47
viewsError when creating a CRUD in ASP.NET Core MVC with Entity Framework?
I am new to programming and am creating a CRUD in ASP.NET Core MVC with Entity Framework, SQL Server database, through an Internet tutorial, downloaded the blessed nugets packages, which are:…
-
0
votes1
answer42
viewsHow do I test the API gateway of a project in microservices
How do I test the Api gateway of a project in microservices? I configured Ocelot.json as below, and when I call in the browser /Billing get the bug:…
-
0
votes0
answers16
viewsCommunication between Applications using Httpclient with SSL error
I have an IIS 10 server with two applications developed by the company. The first, older, is an MVC developed in . Net Framework 4.5. The second, newer, is an API developed in . Net Core 3.1. In…
-
0
votes2
answers214
viewsHow to calculate average students and show in percentage?
I’m trying to create an algorithm in C# as it is in the exercises, in the visual studio, to calculate various average students and show students above average in percentage,I tried a code but this…
-
0
votes1
answer71
viewsModal bootstrap opening a redirect page that should not be inside it
Inside the controller of my partial View that are opened in modal I make a validation if the token is valid, in case everything happens well it will open and show the content, and this happens…
-
0
votes0
answers24
viewsProxy error when accessing controller in ASP.NET core + angular
I’m sending a request for a project that has the structure: Frontend: Angular Backend: ASP.NET Core When sending this request, my controller returns the following message:…
-
0
votes0
answers47
viewsRemove seat seats on the database side with Asp.net core Entity Framework
I have a method that I receive a string, does the search and returns all the data that is equal to the word I passed, like this: public async Task<List<ProductDto>> GetAllAsync(string…
-
0
votes1
answer59
viewsHow to set hostname in publication Asp net core 3.1 selfHosted
I have a working project which the publication preference is in the format of publish to self hosted folder (selfhosted) (without using IIS). Reason for this: the goal is to decrease the…
-
0
votes1
answer30
viewsApplying Runtime Migrations . Net Core
The question is exactly as in the title of this topic, but all the help I found related to the subject is running the code on the application startup requiring arguments to be passed to the host. I…
-
0
votes1
answer40
viewsSending File to API with Authorization . Net 5
On my system, I need to send a received form file to an API that will be saved in Azure. For this submission I need to pass a Bearer Token, the part of the token I was able to do and receive,…
-
0
votes0
answers12
viewsHow to remove extra return tags added by Soapcore?
When using Soapcore no . NET Core 3.1 to incorporate SOAP behavior in my application everything happens as expected, with the exception of the return of two extra tags that inherit the service name…
-
0
votes1
answer12
viewsProblems implementing JWT authentication with NET Core 5
Hello, I’m having trouble implementing JWT in my API, I researched and looked at several tutorials on the subject and noticed that they use Identity, but I use Dapper to be able to check if the user…
-
0
votes0
answers9
viewsProblem running video. net core
Talk Guys, it’s all right? I’m building an intranet portal in my work on. net core, and I need to add some videos that were posted on another company intranet portal. I have both the possibility of…
-
0
votes0
answers22
viewsEdit using PUT method
I wanted to make an edition by PUT method, but I have some problem with the query string. I could not solve so far because I am a new programmer in . NET Core. I have tried to define route, use…
-
0
votes0
answers23
viewsAdd HTTP response header (Access Control Allow Origin)
In my ASP.NET CORE MVC application I have the dist folder in wwwroot: According to the documentation Static Files in ASP.NET CORE configured the startup class by adding an http response header:…
-
0
votes0
answers26
viewsNpgsql.Postgresexception: 53300: remaining Connection slots are reserved for non-replication superuser Connections
I am using Dotnet Core and C# to fetch data from an API and saving to a Postgresql database. And arrives at a certain part of the process in which this error appears: Exception has occurred:…
-
0
votes0
answers16
viewsHow to sort a model
I am having difficulty making an ordering, because I return an object and within that object, I have a list of another object and that list needs to be ordered by a property. The point is, when I…
-
0
votes0
answers11
viewsSectiongroup (XML) data - Dotnet Core
I need to search "sectionGroup" values, as I had to do several sections, it is necessary to use it, however, when trying to search, the value always receives Error. Knowing that There is no…
-
0
votes0
answers18
viewsAjax request using Asp . net core
I’m having trouble with this request... It’s returning 'not been' on the console. The getValue() method is in the Controller/Homecontroller.Cs /* JS */ var obj = { emails: 'teste' } var json =…
-
0
votes0
answers17
viewsHow to consult the Database via Ajax?
In Asp Net Core (I have 03 Models - I will describe well summarized): (Model 01) public class Estudante { public int EstudanteID { get; set; } public string EstudanteNome { get; set; } } (Model 02)…
-
0
votes0
answers8
views.NET Core - Addhttpclient returning null
In an ASP.NET Webapi project I am trying to register a typed http client in the DI container. But when trying to configure using the service Provider ends up returning null in the service. Ambiente…