title: ASP.NET MVC A problem with passing a string object into View
body: <p>I want to pass a string object into a View:</p>
  
  <pre><code> &lt;%@ Page Title="" Language="C#" 
       MasterPageFile="~/Views/Shared/Site.Master"
       Inherits="System.Web.Mvc.ViewPage&lt;String&gt;" %&gt;
  
     &lt;asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server"&gt;
  
            &lt;h2&gt;&lt;%=Model %&gt;&lt;/h2&gt;
  
     &lt;/asp:Content&gt;
  </code></pre>
  
  <p>When I try this:</p>
  
  <pre><code> return View("SomeView", "stringToPass");
  </code></pre>
  
  <p>the error occurs: <strong>The view 'SomeView' or its master was not found.</strong></p>
  
  <p>but, when I change the return to</p>
  
  <pre><code>return View("SomeView");
  </code></pre>
  
  <p>everything works fine. So how to pass that string ?</p>