title: How do I sort negative and positive values from a datagridview in vb.net?
body: <p>I am relatively new to coding, and i was hoping someone could help me with sorting a column of negative and positive values in a datagridview. It is not connected to a datatable, as I am only reading the values from a textfile, that uses commas to separate each bits of data and display it in the datagridview. I have tried to use this code:</p>
  
  <pre><code>DGV.Sort(DGV.Columns(2), System.ComponentModel.ListSortDirection.descending)
  </code></pre>
  
  <p>However it only sorts according to the first integer of the value, and ignores the negative sign, so for example if the cells under that column had</p>
  
  <pre><code>3
  -5
  -2
  </code></pre>
  
  <p>It would sort so it would be </p>
  
  <pre><code>-5
  3
  -2
  </code></pre>
  
  <p>How can I sort so it takes the negative sign into account?</p>