asp.net-mvc

One MVC Project or Two?

We have a large MVC .NET website for a hospital; it has a Doctor Portal, and a Patient Portal. In essence it is two sites, with very little feature overlap. We outsourced the Doctor part to a Vendor and now we are creating the Patient part. I am recommending that we create two separate MVC projects since we are creating the Patient por...

ASP.net MVC - Multiple Forms on View, each calling a different action, but need to show the same view again

I have 3 forms on my View. Each of these all post back to a different action. When the action is complete, I call my original Action that led the user to the page originally, but MVC is looking for a view of the postback Action. How can I get MVC to post to an action of a different name of the current view, while still having it reloa...

How to implement Log4net for my Asp.net mvc application

Hello Friends, I want to Implement Logging future using log4net for my asp.net mvc application.. Can any body has the Sample project so that I can take a look? and where do i need to find out the dll's for log4net? Thanks I Used this link to implement Loging for my application http://www.codeproject.com/KB/aspnet/log4net.aspx How do...

MVC2 Cookieless Session Issue using POST

For some reason with cookieless session enabled in MVC2, the session id in the query string is reset with every form post that happens. Is there a special route that needs to be setup for this to work? Are there any other gotcha's I need to be aware of? Thanks. ...

ASP.Net MVC: Html.Display() for object in a Collection

The standard MVC example to draw an item with the appropriate View Template is: Html.DisplayFor(m => m.Date) If the Model object has a property named Date of type DateTime, this returns a string with the HTML from the Display/DateTime.ascx template. Suppose you wanted to do the same thing, but couldn't use the strongly-typed version -...

Spell Checker for my asp.net mvc application

hello Friends, Can any one provide me a good tutorial about to implement spell checker? that is I have a textarea and one button.. what ever I enterd in to the textarea i need to do the spellchecking on that.. thanks Thanks ...

What are some 3rd party UI components for .NET MVC 2?

Hi. I'm looking for a 3rd party UI component library to be used in .NET 4.0 C# MVC2 web application. When I google it, Telerik comes up all over the first google page. To be honest, I actually do like it a lot. So, I'm just wondering what are other alternatives out there? What are some drawbacks/problems that people have experienced...

MVC Error when opening a project from TFS

I have created an asp.net MVC application in VS 2010, and am using TFS. When another programmer opened my application from TFS and tries to run it (he is also using VS 2010) He gets an error saying type or namespace MVC cannot be found in System.web what do we need to do to get this to build on his machine? Thanks! ...

Entity Framework -- How to set properties to special types

Hi All, I'm new to MVC and Entity Framework, so this may be a relatively simple answer, but I've tried searching around so far and no luck. I'm using the most recent versions of both tools to my knowledge (MVC 3 Beta and Entity Framework 4.0) I'm just trying to set up a quick example. Logically, I'm dealing with events -- in this case...

How to add two assemblies with the same name into an asp.net mvc project

I'm using the Facebook Toolkit inside my Asp.net MVC Application. But now I like to use the Facebook c# Sdk as well, exspecially to test, which one works better for me. Sadly they both consist of three assemblies that have the same name: Facebook Facebook.Web Facebook.Web.Mvc How can I still include both in my project? ...

What is the best way to implement restful routing in ASP.NET MVC 2?

Missing my Rails map.resources and wondering how I can implement something similar in ASP.NET MVC 2. Thanks ...

asp.net mvc application improving Efficiencey suggestions

Please can any body provide me suggestions for standards that you feel are necessary or are areas where effciency/maintenance would improve through standardization. Like GUI,Controller,Repository. Any ideas reagrding ViewModels can be specified under the Controller section? if we place any good results? Thanks ...

jqGrid: using multiple methods to filter data

My requirement is to show a page with multiple filters to apply to grid data. Suppose we are talking about Orders and an order has the following attributes public class Order { public int OrderID public DateTime OrderDate public DateTime ShipmentDate public int OrderTotal public int OrderStatus } Inside the jqgrid...

Retrieving form values from ASP.NET MVC application

Hi, I am learning ASP.NET MVC, and ran across a video on the asp.net/mvc website that showed how to retrieve a value from a textbox after a postback. In the video the author simply grabs the value from the Request object in the controller. It seems like this breaks the separation of concerns concept? By doing this the controller is ...

How to pass the anti-forgery token an action method with the HttpDelete attribute in ASP.NET MVC?

Is this even possible? Code looks like this ... [Transaction] [ValidateAntiForgeryToken] [HttpDelete] public ActionResult Delete(int id) { ...} ...

setting culture in MVC Ajax request

In my view I have the following code (for checking if user exists): $('#CheckAvailability').click(function () { var username = $('#Member_Username').val(); var oldusername = $('#Member_Oldusername').val(); if (username != null) { $.ajax({ type: "GET", url: "/Admin/M...

ASP.NET CMS - which one?

Hi We have a lot clients with CMS requirements. We use Telerik Sitefinity, which is pretty easy to use, but before we implement a whole swathe of new apps, I just want to double check we are going the right way? Telerik is a reliable company. I am not interested in "free" CMS products that will probably disappear a few years down the...

how to pull ads to your website using asp.net mvc

I'm very new on website advertisements. How can i pull ads to my website like what stackoverflow did on their site that i can see on the right side panel? I'm using asp.net mvc. What is the best free ads service to use or an API good for mvc? any suggestion? ...

Grid like styling with jquery Treeview

Hi, in my project i have hierarchical data and i want to display it in following format i have just downloaded jquery treeview and tried it on a small ul. i want to know if i can make such a display with jquery treeview. if not please suggest some other controls. i m using asp.NET mvc 2 RTM with C# ...

The underlying provider failed on Commit.

Hello, In my mvc asp.net application, I have various modules in that I have insert and edit functionality . Some time I am getting this error: at System.Data.EntityClient.EntityTransaction.Commit() at System.Data.Objects.ObjectContext.SaveChanges(SaveOptions options) at System.Data.Objects.ObjectContext.SaveChanges() at admin.chamb...