title: Read only for column in gridview
body: <p>I had Gridview bind sqldatasource  and I had logins which see gridview and I made roles for these logins som of them cannot see all gridview column so how can I make some columns read only .?</p>
  
  <p>code
    public void CheckLoginAuthorty()
      {</p>
  
  <pre><code>    using (SqlConnection Con = Connection.GetConnection())
      {
          SqlCommand com = new SqlCommand("CheackLoginInRole", Con);
          com.CommandType = CommandType.StoredProcedure;
          com.Parameters.Add(Parameter.NewNVarChar("@Login", Session.Contents["Username"].ToString()));
          object O = com.ExecuteScalar();
  
          if (O != null)
          {
              string S = O.ToString();
  
              if (IsInRole("AR-Translator", O.ToString()))
              {
              ///////// Grideview code/////////////////   
              }
  
              else if (IsInRole("EN-Translator", O.ToString()))
              {
         /////////Grideview code/////////////////   
              }
          }
      }
  }
  </code></pre>