George Laing

George Laing

  • NA
  • 35
  • 0

Limiting decimals

Nov 29 2008 6:40 PM

Hi

 I have a numeric column on a datagrid that I am putting into a textbox, The problem is that the value has 4 decimal places and I want to show no decimals. I am not sure though how to convert it to a decimal. pPrem_Optimized in the grid has 4 decimals I want it to show in the textbox with none. Here is the line does anyone know how to limit it to no decimals?

prem_OptimizedTextBox.Text = Grid_Property.Rows[e.RowIndex].Cells["pPrem_Optimized"].Value.ToString();

Thanks


Answers (2)