Questions tagged as 'asp.net-mvc'

1
answer

Capturing StackOverFlowException

Hello, I'm passing some problems on the server and with the application developed in MVC ... I checked that the site was restarting the application pool alone, so I went into Event Viweer and realized that the application is experiencing S...
asked by 10.05.2017 / 02:10
3
answers

Build string with special characters

I'm building PDF's, and I need to print a string with special characters. For this I am constructing the string as follows (using iTextSharp ): PdfPCell teste = new PdfPCell(new Phrase("<O meu texto> '\u20ac'", fontetexto)); Now...
asked by 28.02.2014 / 16:05
1
answer

How to list products from a single restaurant?

I have registered my products at a particular restaurant. Being Restaurant (1) and Products (N), I have several products registered in a restaurant. How do I list these products for each restaurant? This is the default Action: public Act...
asked by 28.09.2016 / 05:23
2
answers

ASP.NET MVC Session

Personal I have a controller where I set two session keys and they capture these key anywhere in the application. (other controller , or a view ). The controller looks like this: [HttpGet] public ActionResult TimetableSelect(int curre...
asked by 24.05.2016 / 18:04
2
answers

How to catch Exception generated by a method whose access is not authorized by a given user profile

How can I send the user a message that the operation he wants to do is not allowed? I have in my View a button that calls a Javascript function <button id="btninicio" onclick="salvaApontamento();">Inicio</button> This sal...
asked by 13.07.2015 / 16:09
2
answers

Could not load file or assembly 'WebGrease, Version = 1.3.0.0, Culture = neutral

I'm just opening a new project based on MVC 5, framework 4.0, C #, and after opening the project for the first time and compiling, the error occurs Não foi possível carregar arquivo ou assembly 'WebGrease, Version=1.3.0.0, Culture=neutral, Pub...
asked by 31.07.2015 / 16:00
2
answers

How to access Action on another Controller via Ajax?

I have an AspNet MVC project structured as follows: Projeto L Areas L Area1 L Controllers L MeuControllerArea1Controller.cs...
asked by 28.08.2015 / 15:56
1
answer

How to send data from AngularJS to an ASP.NET MVC backend?

What would be the best and simplest alternative? I have the Web Api: using System; using System.Collections.Generic; using System.Linq; using System.Net; using System.Net.Http; using System.Web.Http; using Generico.Dominio; using Generico.A...
asked by 04.01.2016 / 02:12
1
answer

How to validate start date and end date for a same attribute of Model

Problem description: I need to create a form with a start date and end date to list the sales of a product by period. Let's take this model as an example: public class Produto { [Display(Name = "ID")] public int IdProduto { get;...
asked by 26.09.2014 / 16:23
2
answers

Give height and overflow-y in a div

I'm trying to give height and overflow-y to div to limit the size of div and add a scroll. Something like this: ForthisIamloadingalistofdatacomingfromDB(IamworkingonASPMVC)inthediv,andIaddtheheightandtheoverflow...
asked by 17.04.2014 / 11:33