Questions tagged as 'asp.net-core'

1
answer

Conditional optimization

Is it possible to make a comparison (if equal to 1 or equal to null ) simpler than the one made in my code? @((Model.Visibilidade == 1 || Model.Visibilidade == null) ? "checked" : "")     
asked by 29.03.2017 / 14:49
1
answer

What is the advantage of using Tag Helpers in ASP.Net Core?

I'm studying ASP.NET Core and came across the tag helpers when I generated the scaffold of a view . I found the new syntax interesting, the code is more readable on some points, however, adding another DLL to all views that used tag help...
asked by 30.12.2015 / 13:25
1
answer

What is the purpose of the asp-area attribute in ASP.NET Core MVC Web?

Creating an ASP.NET Core MVC Web project in Visual Studio 2017 , I found that in the _Layout.cshtml a has an attribute called asp-area but it has no value: <li><a asp-area="" asp-controller="Home" asp-action="Index">H...
asked by 05.06.2018 / 12:23
2
answers

What is ASP.NET Core Blazor?

Looking at the list of news that is in Visual Studio, I came across something talking about ASP.NET Core Blazor, and apparently has almost nothing talking about, I found very little material, and in English, but even using the translator was ver...
asked by 04.04.2018 / 05:01
1
answer

Return message along with UnauthorizedResult

I'm 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 requisitions and act on a set of business rules. It is worth pointing out that I can not change the API itse...
asked by 12.09.2017 / 16:43
1
answer

Request arrives null in C #

I have a request that is being made this way in angle 5. enviarEmail(titulo: TitulosCobranca, unidade: UnidadeEmpresa) { let param: any = { titulo: titulo, unidade: unidade } return this.http.post(this.UrlService + '/T...
asked by 18.05.2018 / 13:59
1
answer

ASP.NET Core Paging - PagedList.Core

I am creating an ASP.NET core study project, and when using the PagedList.Core paging library, the following error is occurring when running the dotnet run command:    Startup.cs (49.35): error CS0246: The name of the type or na...
asked by 09.09.2018 / 20:50
1
answer

Entity Framework Core 2.0 - Add-Migration does not work

I'm creating a new code-first project. When trying to create the migration, using the [Add-Migration Initial -Context LogAuditoriaContext] command it simply does nothing, does not create, does not give error, does not report anything: I have...
asked by 27.12.2017 / 14:43
1
answer

Upload with ASP.NET Core json vs formdata

I'm using asp.net core webapi , initially my actions were using the [FromBody] attribute in the parameters, so I redeemed the json value sent by the front end . Now I'm implementing a screen that has upload , and I had to use formdata to sen...
asked by 01.09.2017 / 13:20
1
answer

Asp.Net 5 (Core 1.0) Class Library System.Text.RegularExpression

How to use the System.Text.RegularExpression namespace in Asp.Net 5, I'm having a project and I was upgrading it to ASP.NET 5, my problem was that I can not use regular expressions in the same en as I can reference the namespace in issue.     
asked by 05.03.2016 / 15:54