Questions tagged as 'asp.net-mvc-5'

3
answers

Footer is not positioned at the bottom of the page

My css: #rodape { position:absolute; bottom: 0; } .RodapeFaleConosco { float:right; } .RodapeTermoPolitica { float: left; } Now my code in jquery to load html str += '<div id="rodape">'; str +=...
asked by 07.05.2014 / 00:38
1
answer

Query with PagedList

I'm using PagedList.Mvc for pagination of results. But when doing the following action with the querys: public ActionResult Index(int? page, string searchString) { int pageSize = 10; int pageNumber = (page ?? 1);...
asked by 24.12.2014 / 17:32
2
answers

Error using methods to generate hash and paste MAC address

According to this my question , in the Cigano's response to the hash of the mac address of the network card, just use two methods. But how to use them to retrieve the data and do the verification I'm having an error:    A field initia...
asked by 25.11.2014 / 23:23
4
answers

How to create a switch..case with ranges of values?

If a total of days is greater than 30 and less than 60, I do something. If it's bigger than 60 and smaller than 90 I do something else and so on. How do I case ? Is case the best option?     
asked by 26.03.2014 / 13:53
2
answers

How do I make a foreach within the View in a ViewData

These are my ViewData in controller: public ActionResult Acao() { RupturaEntities db = new RupturaEntities(); var _listaUnidade = Enumerable.Empty<object>(); var _listaFamilia = Enumerable.E...
asked by 19.09.2014 / 15:57
1
answer

Validating date with Jquery

How to do date validation from EditorFor using jquery? wanted to check if the date entered by the user, and if the date he entered is greater than the current date, display a message to him stating the error <div class="form-group">...
asked by 13.11.2016 / 19:07
1
answer

Interface does not recognize same class type with declared DLL

I created a Class Library project and in it a POCO class. I created an Interface (all this following John Sharp's book). Then I created my WS with WCF. Well, in the interface I declared a method of the type of my class created in the Class Libra...
asked by 13.05.2014 / 00:41
3
answers

DataAnnotations problem in string [] fields

I need an help to validate a string[] field, since whenever I send this empty field, it returns error, even though it is in the correct format: The field is this: [RegularExpression(@"^(([A-Za-z0-9]+_+)|([A-Za-z0-9]+\-+)|([A-Za-z...
asked by 19.09.2018 / 21:19
1
answer

How to make a filter before executing action?

Before running action, I want to make a filter to check if the value exists. If the value does not exist, return to specific page (Index, Home). Any solution?     
asked by 17.02.2017 / 00:38
1
answer

javascript query in asp.net controller [closed]

I need to make a query in a API (JavaScript) method of google maps , however by controller , is it possible? I have a ajax request that assembles a grid and inside it I make a query in the dbo.Atlas table by setting lat...
asked by 26.09.2018 / 20:32