Esempio n. 1
0
        private void MyDgv_CellFormatting(object sender, DataGridViewCellFormattingEventArgs e)
        {
            try
            {
                DataGridView dgv = (DataGridView)sender;

                DataGridViewHelpers.FixFormatting(dgv, e);

                if (CellFont != null)
                {
                    e.CellStyle.Font = CellFont; // new Font("Arial", 16.0F, GraphicsUnit.Pixel);
                }
                if (DoublesPrecision != int.MaxValue)
                {
                    DataGridViewHelpers.FormatDoubles(dgv, e);
                }
            }
            catch (Exception ex)
            {
                throw new ApplicationException(string.Format("Name={0} Err={1}", MyDgv.Name, ex.ToString()));
            }
        }
Esempio n. 2
0
 private void MyDgv_DataError(object sender, DataGridViewDataErrorEventArgs e)
 {
     DataGridViewHelpers.CheckDataError(e);
 }