In most cases it is better to refactor than rewrite a full codebase. We have quite interesting situation. In our application business layer is pretty good. With unit tests, separation of concerns, etc. It does have some problems, but it can be refactored.
However UI layer is outdated. It is ASP.NET + some AJAX, but we want to migrate to pure AJAX application (ExtJS + REST). The application is quite large and has about 100 separate screens. What would you advise?