title: DataGridView gives an error if a table field is binary type
body: <p>For some reasons, i need to write my own sqlquery tool. it generally works.</p>
  
  <p><img src="https://i.stack.imgur.com/SUZuc.png" alt="enter image description here"></p>
  
  <p>But when i select a table which contains a binary type, it gives me the error i've shown it below.</p>
  
  <p><img src="https://i.stack.imgur.com/e9dpn.png" alt="enter image description here"></p>
  
  <p>I used a DatagridView. My code is below.</p>
  
  <pre><code>        private void button1_Click(object sender, EventArgs e)
      {
          string SQL = txtSQL.Text.Trim().ToString();
  
          try
          {
              gridResult.DataSource = getDataset(SQL).Tables[0];
  
          }
          catch (SqlException err)
          {
              MessageBox.Show("Error : " + err.Message + "-" + err.Number);
          }
  
      }
  
      public DataSet getDataset(string SQL)
      {
          SqlConnection conn = new SqlConnection(connStr);
          SqlDataAdapter da = new SqlDataAdapter();
          SqlCommand cmd = conn.CreateCommand();
          cmd.CommandText = SQL;
          da.SelectCommand = cmd;
          DataSet ds = new DataSet();
  
          conn.Open();
          da.Fill(ds);
          conn.Close();
  
          return ds;
  
      }
  </code></pre>
  
  <p>I wonder, Is there any way to prevent showing binary area or prevent giving error? What should do now? Or do you have any idea how can i detect the type of binary field when loading into the gridview programatically?</p>