Ajax + ASP.NET MVC + Exception .... not working ?

Ajax + ASP.NET MVC + Exception .... not working ?

Hello,

I call my ASP.NET MVC controller like this :

  1. $.ajax({
        type: "POST",
        url: "/Product/SaveOrUpdate",
        data: {
            id: getId(),
            name: getName()
        },
        success: function(data) {
        },
        error: function(XMLHttpRequest, textStatus, errorThrown) {
        }
    })










My controller look this

  1. [AcceptVerbs(HttpVerbs.Post)]
    public ActionResult SaveOrUpdate(Guid id, string name)
    {
        try
        {
            //Code here and this code generate an MyPersonalException exception
            return Index();
        }
        catch (MyPersonalException)
        {
            _model.ErrorMessage = ex.Message;
            return View("MessageError", _model);
        }
    }












when no exception it's ok. When there is an exception, I build an another View (it's a div blinking with the message in). I'd like display this view, only this view. I don't care the error number (500), I just want show the HTML received, created in the view and display in a <div> :)

I tried several solution found on the web but without any success.

Using jQuery 1.4.1

Thanks,