title: c# User.IsInRole Namespace
body: <p>Note, I am using c# MVC 3, I am trying to use this within a class, NOT a controller.</p>
  
  <p>I have the following at top of my program</p>
  
  <pre><code>    using System.Web.Security;
  </code></pre>
  
  <p>I tried to do the following but get the message:</p>
  
  <p><em>The name 'User' does not exist in the current context.</em></p>
  
  <p>Here is my partial code:</p>
  
  <pre><code>     using System.Web.Security;
       ....
       ....
  
       if (User.IsInRole("Admin"))  
       {
  
       }
  </code></pre>
  
  <p>I am thinking that is has to do something with the namespace but looking at the documentation, all I should need is System.Web.Security. </p>