title: Access Div Id placed in _Layout MVC3
body: <p>I am working in MVC3. I have created a DIV in _Layout.cshtml file  for showing Error Messages and i have created a C# class ErrorMessage in Views Folder.</p>
  
  <p>DIV in _layout.cshtml file:</p>
  
  <pre><code>&lt;div class="ErrorMessageBox" id="ErrorMessageDiv" runat="server"&gt; &lt;/div&gt;
  </code></pre>
  
  <p>This is class ErrorMessage code:</p>
  
  <pre><code>public static class ErrorMessage
  
  {
      public static void Show(string message)
      {
          ErrorMessageDiv.InnerText = message;
      }
      public static void Hide()
      {
      }
  }
  </code></pre>
  
  <p>In the class ErrorMessage it gives error "ErrorMessageDiv does not exist in current context"</p>
  
  <p>Any idea how to do it in MVC3? </p>