Anyone familiar with MVC/ASP.NET front-end development?

Merad

Platinum Member
May 31, 2010
2,586
19
81
So, I'm tasked with making a small-ish site based around MVC and a SQL Server database. I've not problem with the DB design/coding or the back-end code, but I've never done front-end web stuff at all save some basic HTML long ago. I'm a bit lost with the options since it seems you can use varying combinations of ajax, jquery, mvc, and asp stuff.

For example, there's an admin page where I ask for a user name, look up and verify that the user exists in Active Directory, then select one more groups that this user is added to. Is there a simple way to make a dynamic page that can ask for the user name, then display the results of the AD query without having to reload or redirect to a new page?
 
Last edited:

purbeast0

No Lifer
Sep 13, 2001
52,927
5,797
126
if it were me, i'd use angular for that task, probably just because i've been doing it for a while now and am very familiar with it. it does have kind of a steep learning curve imo, but it can do exactly what you are asking very easily. it's very easy to make backend calls and wait for the data to come back, then have the model update the view.

i haven't done asp/.net stuff so i can't really comment on that part. angular has a bunch of built in ajax calls that are just wrappers i think, but it's pretty easy to use. unfortunately the angular documentation is also terrible so that doesn't help either.

but you could also do all of that with jquery and bootstrap. i'm just not sure if you can do it without reloading or anything though with just those 2 technologies. angular you can do it easily because stuff on the view is bound to a model, and when the model changes, the view will "automatically" change as well.
 

Ken g6

Programming Moderator, Elite Member
Moderator
Dec 11, 1999
16,282
3,903
75
Yeah, and if I was doing it I'd use Drupal. The OP has a specific set of tools he has to use. I think "MVC" even refers to a specific Microsoft implementation of the Model-View-Controller pattern.

So let's keep this thread on-topic.
 

purbeast0

No Lifer
Sep 13, 2001
52,927
5,797
126
oh i thought he was just asking for suggestions. his post doesn't even mention .net
 

Ancalagon44

Diamond Member
Feb 17, 2010
3,274
202
106
You could use MVC for that - you'd have to use AJAX with it to accomplish what you want. Its not that difficult, it took a bit of fiddling for me to get right. I can't remember exactly how I did it, but there are built in controls to do AJAX postbacks. I think you need an AjaxForm if I remember correctly. You also need to modify your controller action to return a partial action result.

Your other option is to use WebAPI controllers instead, and a single page application front end. Angular is an example of a single page application front end. WebAPI is similar in implementation details to MVC, but the single page application stuff is completely different. You write HTML views and Javascript viewmodels for the views. The viewmodels handle events, which can include posting back to the server and updating the view. Or navigating to a different view.

If you want to learn something new, go the WebAPI and single page application route. If you just want it to work, investigate MVC and Ajax.
 

sao123

Lifer
May 27, 2002
12,648
201
106
I have created a very similar page to display active directory information on domain accounts (locked, password age, expiration, group memberships, last login date, exchange GAL info, etc), however I did it using asp.net Web forms rather than mvc. Although it will eventually die off, Web forms is much easier in asp.net than mvc. It is very much like coding with traditional html, and you can use nuget to add in jquery and jquery ui, plus you have access to the ms Ajax control toolkit. It was pretty simple to search and put everything into a gridview, then I used the jqeury tablesorter with that. The specific ASP.net control which allows you to dynamically insert content into the page without doing an entire page refresh (or a new page) is an ASP:UpdatePanel. http://www.asp.net/ajax/documentation/live/overview/updatepaneloverview.aspx
 
Last edited:
sale-70-410-exam    | Exam-200-125-pdf    | we-sale-70-410-exam    | hot-sale-70-410-exam    | Latest-exam-700-603-Dumps    | Dumps-98-363-exams-date    | Certs-200-125-date    | Dumps-300-075-exams-date    | hot-sale-book-C8010-726-book    | Hot-Sale-200-310-Exam    | Exam-Description-200-310-dumps?    | hot-sale-book-200-125-book    | Latest-Updated-300-209-Exam    | Dumps-210-260-exams-date    | Download-200-125-Exam-PDF    | Exam-Description-300-101-dumps    | Certs-300-101-date    | Hot-Sale-300-075-Exam    | Latest-exam-200-125-Dumps    | Exam-Description-200-125-dumps    | Latest-Updated-300-075-Exam    | hot-sale-book-210-260-book    | Dumps-200-901-exams-date    | Certs-200-901-date    | Latest-exam-1Z0-062-Dumps    | Hot-Sale-1Z0-062-Exam    | Certs-CSSLP-date    | 100%-Pass-70-383-Exams    | Latest-JN0-360-real-exam-questions    | 100%-Pass-4A0-100-Real-Exam-Questions    | Dumps-300-135-exams-date    | Passed-200-105-Tech-Exams    | Latest-Updated-200-310-Exam    | Download-300-070-Exam-PDF    | Hot-Sale-JN0-360-Exam    | 100%-Pass-JN0-360-Exams    | 100%-Pass-JN0-360-Real-Exam-Questions    | Dumps-JN0-360-exams-date    | Exam-Description-1Z0-876-dumps    | Latest-exam-1Z0-876-Dumps    | Dumps-HPE0-Y53-exams-date    | 2017-Latest-HPE0-Y53-Exam    | 100%-Pass-HPE0-Y53-Real-Exam-Questions    | Pass-4A0-100-Exam    | Latest-4A0-100-Questions    | Dumps-98-365-exams-date    | 2017-Latest-98-365-Exam    | 100%-Pass-VCS-254-Exams    | 2017-Latest-VCS-273-Exam    | Dumps-200-355-exams-date    | 2017-Latest-300-320-Exam    | Pass-300-101-Exam    | 100%-Pass-300-115-Exams    |
http://www.portvapes.co.uk/    | http://www.portvapes.co.uk/    |