Most voted "asp.net-mvc-5" questions
This tag should be used when the question refers to some features only available in version 5 (currently the latest) of ASP.Net MVC. ASP.NET MVC is an open-source Microsoft framework that implements the Model View Controller architecture standards for web development. Based on ASP.Net, allows software developers to build web applications following the Model View Controller architecture standards.
Learn more…937 questions
Sort by count of
-
0
votes0
answers20
viewsId value is not changing in ASP.NET MVC 5
I am creating a CRUD in ASP.NET in my project, however, started to give a problem. When I try to delete a Product, it passes the totally different Id to the other View, an Id that does not match the…
-
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
votes0
answers251
viewsValue cannot be null. Name of parameter: entitySet
I am trying to make a project of an e-commerce of Petshop in ASP.NET MVC with Entityframework. Everything was going well, until suddenly, when I tried to register or even list Vendor, this error…
asp.net-mvc entity-framework asp.net-mvc-5 visual-studio entity-framework-6asked 3 years, 12 months ago Leo 29 -
0
votes0
answers41
viewsShopping Cart Doesn’t Let You Add More Items After Cleaning It
I’m making a shopping cart for an E-commerce test on ASP.NET MVC, working with EF6. I was doing the logic, the cart it adds products and also removes. However, every time I add several products, and…
asp.net-mvc asp.net entity-framework asp.net-mvc-5 entity-framework-6asked 3 years, 11 months ago Leo 29 -
0
votes1
answer78
viewsIn Clean Architecture, which layer receives the business rules and logic specific to a system?
Speaking of Clean Architecture, we usually see examples of a basic CRUD system, but that do not show where are located the codes of controllers that need a complexity a little more than simply a…
-
0
votes0
answers29
views@Html.Pagedlistpager No Bootstrap
I am building a small project in Asp.net MVC and I need to make use of the X.Pagedlist library, I was able to make the pagination all right, but it is not applying the Bootstrap, which should be…
-
0
votes1
answer21
viewsHide form after uploading a file
Hello, I have a view that has more than one form and in each form, I specify the type of document that will be uploaded. ex: Form1 has an Hidden input with value = 1, for Cpf... form2 value = 2, for…
-
-1
votes1
answer110
viewsCSHTML with tabs is leaving a horizontal line at the bottom of the page
I have a page with 4 tabs. It’s working. I happen to have a div for each tab. The end of the tab and the beginning of the other tab looks like this: ..... </div> </form> </div>…
-
-1
votes1
answer106
viewsDoubt in the construction of WS REST(Contract)
Gentlemen, I took an example in the book of john Sharp(microsoft press) to build a REST and came a simple doubt, but a doubt of good practices. He uses the Northwind BD. He creates a Class Library…
-
-1
votes1
answer332
viewsAttribute not recognized, but Namespace is added
My attribute [DataContract] is not being recognized, but the namespace System.Runtime.Serialization is added in my using. Does anyone know why? .... using System.Runtime.Serialization; using…
-
-1
votes1
answer133
viewsDoes Try Catch influence performance?
Utilise Try...Catch influence on performance? in memory usage? Would be a problem if all actions you do have error handling? try { clienteRepository.Salvar(entity); } catch (Exception e) {…
-
-1
votes1
answer104
viewsForeach result behaves unexpected
I have been working on a page, where I need to create a treeview system with checkbox and this is consuming a lot of my time and leaves me worried about the project’s SLA. In the controller, there I…
-
-1
votes2
answers568
viewsHow I do a foreach inside the View in a Viewdata
Those are my Viewdata on the controller: public ActionResult Acao() { RupturaEntities db = new RupturaEntities(); var _listaUnidade = Enumerable.Empty<object>(); var _listaFamilia =…
-
-1
votes2
answers69
viewsError while using methods to generate hash and catch MAC address
According to my question, in the Gypsy’s response to hash of mac address network card just use two methods. But in the form of using them to retrieve the data and do the check I’m having an error: A…
-
-1
votes1
answer181
viewsHow to make a filter before performing action?
Before executing action, I want to make a filter to check if the value exists. If value does not exist, return to specific page(Index, Home). Some solution ?
asp.net-mvc-5asked 7 years, 9 months ago Matheus Miranda 5,375 -
-1
votes1
answer24
viewsDo dates search using MVC5
Good afternoon, guys, okay? I hope so. I’m having doubts about ordering the database data in ascending order of dates. var result = from r in context.name Where r.numero == 2 orderby r.datacadastro…
-
-1
votes2
answers783
viewsHow to execute method by clicking a button type
Ola, I am making an application that can re-cover the user password and send the password to the Suport team email. For that I have a page .aspx that has html code and I have it in the class…
-
-1
votes1
answer566
viewsDate validation with Jquery
How to do date validation from Editorfor using jquery? wanted to check if the date typed by the user, and if the date he typed is greater than the current date, display a message to him stating the…
-
-1
votes1
answer427
viewsDecimal type field Entity Framework ASP.NET MVC
I have a table called Pecas where only has name and value, but when I click create new piece is not saving in the database, appears the msg that was added but is not entering, in debug shows the…
-
-1
votes3
answers121
viewsDataannotations problem in string fields[]
I need help validating a field string[], because whenever I send this empty field, it returns error, even if it is in the correct format: This is the field:…
-
-1
votes1
answer44
viewsQuery javascript in the Asp.net controller
I need to make a query on a method of API (Javascript) of google maps, however by controller, it is possible ? I have a requisition ajax that mounts a grid and within it I make a query in the table…
-
-1
votes1
answer124
viewsI cannot perform a Redirecttoaction for an Area
Print of what I’ve accomplished, but it didn’t work, this is my Logincontroller. My structure, and I’m trying to point to the Patientecontroller/Index: One of the other options I tried was to add…
-
-1
votes1
answer3469
viewsASP . net core (HTTP error 500.19 - Internal Server Error)
I have a web api, which when running on Iss presents error 500.19 in the browser, I am very new in the subject, I did some research this error may be on web.cofing. If anyone can help me, thank you!…
asp.net-mvc-5 asp.net-core asp.net-web-api iis visual-studio-2017asked 5 years, 5 months ago Matheus Vinicius 23 -
-1
votes1
answer204
viewsPagination with search
I am trying to create a search in a grid with paging, but when it brings the search result it generates a new pagination but when I click on page 2 it brings all the results ignoring the search and…
-
-1
votes1
answer27
viewsHow to do one authentication for two different applications on MVC5?
Hey there, guys. I have two ASP.NET MVC5 applications on the same server on the same site. I’m trying to make one authentication valid for both projects. I have already set a cookie name for both…
asp.net-mvc asp.net asp.net-mvc-5 asp.net-identity identityasked 4 years, 4 months ago Gustavo Borges 19 -
-2
votes1
answer118
viewsAssign existing view to a controller
I have a view q is assigned to a controller. Everything was in this controller. Now we decided to create a controller for every situation we have here. Only I wouldn’t want to create a new view,…
asp.net-mvc-5asked 10 years, 7 months ago pnet 14,727 -
-2
votes2
answers183
viewsShow information when no data
I made a if, in case something comes back, then he mounts a page, otherwise he should hide everything and show a message. It’s not an Alert, but a message on the same page. On my Lse I just hide a…
asp.net-mvc-5asked 10 years, 7 months ago pnet 14,727 -
-2
votes2
answers314
viewsReturn a class in jQuery
I have these Hidden fields in my cshtml: <input type="hidden" id="txtGeoTo" name="txtGeoTo" /> <input type="hidden" id="txtDateStart" name="txtDateStart" /> <input type="hidden"…
-
-2
votes1
answer110
viewsWhen I load the class in the view, it gives Nullexception error
That’s the mistake you’re making: This is the error line in my cshtml @( new HtmlString((SessaoUtil.Recuperar("TagGoogle") != null ? SessaoUtil.Recuperar("TagGoogle").ToString() : ""))) This is my…
asp.net-mvc-5asked 10 years, 7 months ago pnet 14,727 -
-2
votes0
answers10
viewsLearn . NET Core
I have been developing for a while in . NET Framework (webforms, windows Forms) and am learning . NET Framework MVC. I saw Maniero’s response in several posts talking about Core and the "death" of…
-
-2
votes1
answer269
viewsPut Asp Net MVC Identity validation
I tried to locate this doubt in the forum and could not find. I have an Asp Net MVC application that uses the Entity Framework with Identity to login. My client registration works perfectly, but I’m…
asp.net-mvc entity-framework asp.net-mvc-5 asp asp.net-identityasked 6 years, 9 months ago Mauricio3012 31 -
-2
votes1
answer73
viewsReturn data from the Customer
Good morning Personal, I would like to create a function, which returns the requested client, and its data, which are in 3 different tables Clientes, ClientesTelephone, ClientesEmail, I can add the…
-
-2
votes1
answer147
viewscontroller with the same name (home) in different areas
I have problem of ambiguity, when having controllers, with the same name as, Homecontroller in two areas: Admin and Backoffice is me presenting the problem of ambiguity, I’ve searched enough subject…
-
-2
votes1
answer65
viewsFormatting Javascript data
The date is filled in according to the information obtained from a JSON response Script $(document).ready(function () { $("#@(Model.Campo)_Nome").typeahead({ source: function (query, process) {…
-
-3
votes5
answers2197
viewsHow to create a switch.. case with value ranges?
If a total of days is over 30 and under 60, I do something. If it’s over 60 and under 90 I do something else and so on. How do I do this case? Did the case is the best option?…
-
-3
votes1
answer1703
viewsBring the last five in a row
I have a table of events. And each POS, an event is held, with the Event ID, Date, User and Type. Well, whenever I make a query, I populate an event grid. I would like to know, how to bring the last…
-
-3
votes2
answers67
viewsPosting of a website
I would like to know, what is the average amount spent to publish an e-commerce site on the Internet, with databases, domain purchase and so on... and what exactly would I have to do to stay…