In this article I will explain with an example, how to use Response.Write in ASP.Net MVC.
Response.Write function is not available in ASP.Net MVC and hence this article will illustrate how to do similar functionality in ASP.Net MVC.
Note: For beginners in ASP.Net MVC, please refer my article ASP.Net MVC Hello World Tutorial with Sample Program example.
 
 
Controller
The Controller consists of the following Action method.
Action method for handling GET operation
Inside this Action method, the string message is sent to the Client using Content function.
Note: The Content function sends the data to the Response similar to Response.Write function.
 
public class HomeController : Controller
{
    public ActionResult Index()
    {
        return Content("Hello MVC!");
    }
}
 
 
View
There is no programming required inside the View and hence this section is skipped.
 
 
Screenshot
Using Response.Write in ASP.Net MVC
 
 
Downloads