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
-
29
votes1
answer916
viewsWhy was . NET Core created?
I already know what it is and how to use it, but wanted to understand the goal of Microsoft for its creation. I know I had problems in the . NET Framework, but I don’t really understand why they…
-
21
votes2
answers1634
viewsWhat is ASP.NET vNext? What is the correct name?
Okay, I know that ASP.NET vNext is the new version of ASP.NET being released by Microsoft in 2015 and that brings big changes changing the way of working various things. This vNext name was used as…
asp.net-mvc asp.net asp.net-web-api asp.net-core nomenclatureasked 9 years, 9 months ago Maniero 444,682 -
17
votes2
answers1493
viewsWhat can I do in . NET Framework and . NET Core not? And vice versa
I grew my eye on . NET Core (ASP.NET Core), I started with C#, but I left it by going sideways "open-source", now with this opportunity I decided to "return". I intend to use . NET Core (ASP.NET…
-
14
votes1
answer678
viewsIs . NET Core stable enough for production?
The . NET Core is already stable and reliable to the point of being used in production environments for commercial websites?
-
11
votes1
answer219
viewsHow was the relationship between Web Api and Asp.NET MVC in Asp.NET 5?
Us ASP.NET 4.6 or less there were differences between Web Api and Asp.Net MVC. O controller, may inherit from controller or of ApiController. However, with the arrival of the Asp.Net 5 will not have…
-
10
votes1
answer834
viewsHow is the life cycle of an ASP.NET 5 application?
This is a question that I have always had (including in previous versions of ASP.NET), but I will ask here in the context of ASP.NET 5. The question is this: when building an application with…
-
10
votes1
answer130
viewsFunctionality of ":" in C#
Recently I was developing a C# application with Visual Studio and I came across a somewhat unusual situation: public void Upload(object model) { FOO: var text = "teste"; } In the code, FOO: does not…
-
9
votes2
answers1119
viewsWhere is Session stored in ASP.NET Core and how best to use it?
Knowing that ASP.NET MVC when it comes to Session should be taken care not to abuse too much of such functionality due to its memory consumption by the server can "weigh" the application. Reading a…
-
8
votes1
answer1303
viewsWhat is and how does . NET Platform Standard work?
Recently I have studied the . NET Core and ASP.NET Core and one of the changes to the RC2 version that is to come, as far as I know, is called . NET Platform Standard. This standard is described in…
-
8
votes2
answers695
viewsWhat is ASP.NET Core Blazor?
Looking at the list of novelties found in Visual Studio, I came across something talking about ASP.NET Core Blazor, and apparently there’s almost nothing talking about, I found very little material,…
-
7
votes1
answer1806
viewsReportviewer MVC Core
I am working on a project using ASP.NET MVC Core. I installed all the necessary dependencies for the use, but it does not allow to be used in my application. However, if I create a new MVC5…
-
7
votes1
answer239
viewsProject Dependency Injection . Net Web API 2
I am involved in a project that is developing an application .Net Web API 2 Fw 4.51 (with a view to future migration to .Net Core, what is an 'aggravating'), Fluent NHibernate e PostgreSQL, and we…
.net asp.net-web-api dependency-injection asp.net-core iocasked 8 years, 3 months ago Carlos Felippe Vernizze 71 -
6
votes2
answers174
viewsHow in ASP.NET 5 is this property defined?
In ASP.NET 5 in the method Configure class Startup we can receive in the parameters a reference to an object whose class implements IHostingEnvironment. One of the properties of this class is…
-
6
votes0
answers220
viewsHow to use Oauth in ASP.NET 5?
In versions prior to ASP.NET 5, there was a middleware called "Oauth Authorization Server Middleware" that allowed adding an Oauth server to the pipeline and setting up token generation. The…
asp.net security-guard asp.net-web-api oauth asp.net-coreasked 9 years, 6 months ago SomeDeveloper 18,074 -
6
votes2
answers3207
viewsWhat are the differences between ASP.NET MVC and ASP.NET Razor Pages?
What are the differences and limitations between ASP.NET MVC and ASP.NET Razor Pages? I was very curious, because apparently the Razor Pages use the MVC standard, but without the need to use a…
-
6
votes2
answers1375
viewsHow to use DTO in ASP.NET CORE + DDD
I am assembling an application following the DDD standards. I would like to know how to properly use the Data Transfer Object - DTO standard. With the little I’ve read, I’ve come to the conclusion:…
-
5
votes1
answer1032
viewsDependency Injection in . NET Core
I am migrating a Webapi project with . NET Framework 4.6 to . NET Core. In this my project I use Unity to do Dependency Injection: var container = new UnityContainer(); DependencyResolver = new…
-
5
votes1
answer696
viewsHow to set up languages in Asp.net Core
I’m setting up the AddLocalization So the problem is that Resources are in a separate class library of the project and I don’t know how to set up. services.AddLocalization(options =>…
-
5
votes2
answers203
viewsWhen to use "Try catch" in layered application?
Let’s say I have my layers Controller Business Repository so it is necessary to create this block in the 3 layers or create only in the controller? If I do this she ensures that every code that is…
-
5
votes1
answer157
viewsError converting varchar to integer
By performing the following UPDATE through my API (.NET Core): UPDATE Aula SET WHATEVER = WHATEVER WHERE ID_AULA = @examID Code: string query = builder .AppendLine("UPDATE Aula") .AppendLine("SET…
-
5
votes1
answer70
viewsHow to stream video with interval request?
I have a video saved in the database with type VARBINARY(MAX). How can I make a request range ? The following code gets the full video from the database and plays in the variable video_byte; This is…
-
5
votes4
answers1546
viewsTake specific value from a JSON or XML
Hello, I have an entire JSON inside a string and I need to turn it into an object in order to access some data... I’ll leave the code below to see if you can help me. My JSON is in that string:…
-
5
votes1
answer1690
viewsTolistasync() - Sqlnullvalueexception: Data is Null. This method or Property cannot be called on Null values
I’m getting the following error while trying to list all the records of a model: Sqlnullvalueexception: Data is Null. This method or Property cannot be called on Null values.…
-
4
votes1
answer125
viewsASP.NET vNext is interpreted like PHP?
ASP.NET vNext is presenting a lot of news in relation to previous versions, among them is the idea of not compiling the codes, just modify and already see what happens on the page. This means that…
-
4
votes1
answer392
viewsWhat is the advantage of using Tag Helpers in ASP.NET Core?
I am studying the ASP.NET Core and came across the tag helpers when I ran the scaffold of a view. I found interesting the new syntax, the code is more readable at some points, however, the inclusion…
-
4
votes1
answer672
views.Net Core, Dapper and Visual Studio Code?
I’m trying to integrate Dapper into the. Net Core, but I’m not getting and all the tutorials I found, were made in Visual Studio, using Nugget. Then someone could explain me how to import Dapper…
-
4
votes2
answers501
viewsHow do I determine the search path for Controllers and Views?
I’m studying ASP.NET Core MVC on a macOS. When I create a new project, the IDE automatically arrow my Views into a folder called "Home". If I change the name of that folder or change the folder…
-
4
votes3
answers187
viewsHow to understand and deal with the cost of Azure?
I’ve known Azure for a long time, read a lot and watched several videos but never used it. What I know about payment is that you only pay for what you use. It turns out that recently an acquaintance…
software-engineering windows-azure asp.net-core project-management microservicesasked 7 years, 4 months ago SomeDeveloper 18,074 -
4
votes1
answer593
viewsReturn message together with Unauthorizedresult
I am using . NET Core 2 to create a dependency that will be injected into an API. The idea is to create a middleware to control incoming requests and act according to a number of business rules. It…
-
4
votes1
answer535
viewsWhat is an Over-posting attack?
I came across the term Over-posting while following Microsoft’s guide to creating ASP.NET Core applications. I had made a question regarding the use of attributes in the signature of a method, which…
-
4
votes1
answer37
viewsOther account data with facebook authentication
I am implementing authentication by facebook and wanted to, when entering the application with the account data, save also full name, photo, among other data. Searching, I got the following code:…
-
4
votes1
answer1788
viewsEntity Framework 7, Insert or Update
I’ve been looking for a method to check if an object exists in the base, if it exists, run a update, if there is no, insert. I couldn’t find anything anywhere that would suit me, so I made the…
-
4
votes1
answer823
viewsWhat is the purpose of Concurrencystamp and Securitystamp in ASP.NET Identity?
The summary of both properties in the entity IdentityUser are in English: Concurrencystamp: A Random value that must change Whenever a user is persisted to the store. Translating would be something…
-
4
votes1
answer112
viewsHow to page a query in Azure Cosmos DB?
I’m trying to pay for a consultation on Azure Cosmos DB, reading this post: Paging through query Results in Azure Documentdb, got to the code: public async Task <ICollection <TEntity>>…
-
4
votes0
answers216
viewsFile config Serilog Sink Asp.net Core
I am using the Serilog log log library on ASP.NET Core 2.1 I am using based on the Serilog manual: https://github.com/serilog/serilog-sinks-mssqlserver Normally the configuration file is in…
-
4
votes1
answer180
viewsCustom Data Annotations for validation
I want to create a Data Annotation to be able to check in ALL pages of my application if the user who is logging in already has 1 Condomínio registered, if there is no registered condominium it…
-
4
votes1
answer420
viewsHow to translate "Errormessage" from a "Custom Attribute"
I created a Custom Attribute which is valid only if a property CPF is a valid CPF, but when locating the application I noticed that my Custom Attribute were not having their messages located by the…
-
4
votes1
answer199
viewsHow to read an XML that is inside the project?
I’m creating a web application with .NET Core Razor and I need to get my code to read a file XML. I can already get him to read this XML, but with another path, which is out of my project. That is,…
-
3
votes2
answers865
viewsASP.NET vNext in Apache
I have heard a lot that ASP.NET 5 will work not only on Windows environment but also on Mac and Linux. I was wondering if you can run ASP.NET 5 applications on the Apache server. I searched a little…
-
3
votes1
answer84
viewsAsp.Net 5(Core 1.0) Class Library System.Text.Regularexpression
How to use the namespace System.Text.Regularexpression in Asp.Net 5, I’m with a project and went to upgrade it to Asp.net 5, my problem was that I can’t use regular expressions in it and n can…
-
3
votes1
answer997
viewsAdd Authentication to Asp.net Core project
I created an Asp.Net Core MVC project without authentication. With the project already underway, I need to add the authentication part and I wanted to be able to automatically generate all the files…
-
3
votes1
answer71
viewsCondition optimization
A comparison is possible (if 1 or equal to null) simpler than the one made in my code? @((Model.Visibilidade == 1 || Model.Visibilidade == null) ? "checked" : "")…
-
3
votes1
answer1253
viewsUpload with ASP.NET Core json vs formdata
I’m using Asp.net core webapi, initially my actions were using the attribute [Frombody] in the parameters, so I rescued the json value sent by front-end. I am now implementing a screen that has…
-
3
votes1
answer115
viewsCodetemplate in . net core [scaffolding]
As in . net core 2.0 I do to create custom scaffolding templates? On the old system . net 4.6 copied the Codetemplates folder to the project. No . net core < 2 instavala o…
-
3
votes2
answers719
viewsRefresh ajax mvc core page
I need to close a modal, and refresh the page, I’m doing this way: function closeModal() { $('#myModal').modal('hide'); location.reload(); } But the first time it doesn’t work, and then it works…
-
3
votes1
answer469
viewsWhat is the purpose of the "Asp-area" attribute in Web ASP.NET Core MVC?
Creating a project Web ASP.NET Core MVC in the Visual Studio 2017, I found that in the file _Layout.cshtml all elements a has an attribute called asp-area but it has no value: <li><a…
asp.net-coreasked 6 years, 6 months ago NoobSaibot 9,554 -
3
votes1
answer565
viewsInjection of dependency Generics<T>
Good morning friends. I hit a rough patch and I’m not getting past it. I have 2 projects, a webapi and a standard class, both in dot net core. In my standard design, I am working with Repository to…
mongodb generic dependency-injection .net-core asp.net-coreasked 7 years, 2 months ago Guilherme Dietrich 31 -
3
votes1
answer1644
viewsEntity Framework Core 2.0 - Add-Migration does not work
I am creating a new code-first project. When trying to create Migration, using the command [Add-Migration Initial -Context LogAuditoriaContext] it simply does nothing, creates nothing, makes no…
c# asp.net asp.net-core migrations entity-framework-coreasked 6 years, 12 months ago LeoFelipe 1,455 -
3
votes1
answer512
viewsError: Cannot convert Implicitly
I’m getting the following error. It is not possible to implicitly convert "System.Linch.Iqueryable" to "Testemercos.Models.Applicationproduct". There is an explicit conversion ? in that part of the…
-
3
votes1
answer44
viewsPage inside a Rest Web Api C#
Hello. I am creating a . Net Core C# Rest project, but I have the following question: In the processing of the Rest Post, I will return a URL so that the requesting one can view the result data it…