title: ViewBag - Object reference not found - MVC 3
body: <p>Upon publishing my MVC 3 Web Application to my website I get an error stating an Object reference not set to an instance of an object.</p>
  
  <p>The 'error' line is:
  Line 2:      <code>ViewBag.Title = "Index";</code></p>
  
  <p>This is my Index view:</p>
  
  <pre><code>@{
      Layout = "~/Views/Shared/_Layout.cshtml";
  }
  </code></pre>
  
  <p>This is my Home Controller:</p>
  
  <pre><code>using System;
  using System.Collections.Generic;
  using System.Linq;
  using System.Web;
  using System.Web.Mvc;
  
  namespace WebApplication.Controllers
  {
      public class HomeController : Controller
      {
          //
          // GET: /Home/
  
          public ActionResult Index()
          {
              return View();
          }
  
      }
  }
  </code></pre>
  
  <p>I have uploaded DLL's:</p>
  
  <pre><code>System.Web.Helpers
  System.Web.Mvc
  System.Web.Razor
  System.Web.WebPages
  System.Web.WebPages.Deployment
  System.Web.WebPages.Razor
  </code></pre>
  
  <p>Thanks for any assistance</p>