title: ignore renderbody in razor _layout.cshtml
body: <p>I have a page for what u need to be signed in to watch it. So I want to try this code:</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html lang="de"&gt;
  &lt;head&gt;
      &lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8" /&gt;
      &lt;meta charset="utf-8" /&gt;
      &lt;title&gt;@ViewBag.Title - Meine ASP.NET MVC-Anwendung&lt;/title&gt;
      &lt;link href="~/favicon.ico" rel="shortcut icon" type="image/x-icon" /&gt;
      &lt;meta name="viewport" content="width=device-width" /&gt;
      @Styles.Render("~/Content/css")
      @if (!Request.IsAuthenticated) {
          @Styles.Render("~/Content/signin")
      }
      @Scripts.Render("~/bundles/modernizr")
  &lt;/head&gt;
  &lt;body&gt;
      @if (Request.IsAuthenticated) {
          &lt;header class="navbar navbar-fixed-top" role="banner"&gt;
              &lt;div class="container"&gt;
                  &lt;div class="navbar-header"&gt;
                      &lt;button class="navbar-toggle" type="button" data-toggle="collapse" data-target=".bs-navbar-collapse"&gt;
                          &lt;span class="icon-bar"&gt;&lt;/span&gt;
                          &lt;span class="icon-bar"&gt;&lt;/span&gt;
                          &lt;span class="icon-bar"&gt;&lt;/span&gt;
                      &lt;/button&gt;
                      &lt;a class="navbar-brand" href="../"&gt;Home&lt;/a&gt;
                  &lt;/div&gt;
                  &lt;nav class="collapse navbar-collapse bs-navbar-collapse" role="navigation"&gt;
                      &lt;ul class="nav navbar-nav"&gt;
                          &lt;li class="active"&gt;
                              &lt;a href="#"&gt;Link 1&lt;/a&gt;
                          &lt;/li&gt;
                          &lt;li&gt;
                              &lt;a href="#"&gt;Link 2&lt;/a&gt;
                          &lt;/li&gt;
                          &lt;li&gt;
                              &lt;a href="#"&gt;Link 3&lt;/a&gt;
                          &lt;/li&gt;
                          &lt;li&gt;
                              &lt;a href="#"&gt;Link 4&lt;/a&gt;
                          &lt;/li&gt;
                          &lt;li&gt;
                              &lt;a href="#"&gt;Link 5&lt;/a&gt;
                          &lt;/li&gt;
                      &lt;/ul&gt;
                  &lt;/nav&gt;
              &lt;/div&gt;
          &lt;/header&gt;
          &lt;div id="body"&gt;
              @RenderBody()
          &lt;/div&gt;
      } else {
          @RenderBody()
      }
      @Scripts.Render("~/bundles/jquery")
      @Scripts.Render("~/bundles/jqueryval")
      @Scripts.Render("~/bundles/bootstrap")
      &lt;footer&gt;
          &lt;p&gt;&amp;copy; @DateTime.Now.Year - Meine ASP.NET MVC-Anwendung&lt;/p&gt;
      &lt;/footer&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>But when I start this I get this exception</p>
  
  <pre><code>The RenderBody-Method wasn't called for the layoutpage "~/Views/Shared/_Layout.cshtml"
  </code></pre>
  
  <p>How can I make razor ignore the RenderBody-method?</p>