Пример #1
0
        private void frmSoldItems_Load(object sender, EventArgs e)
        {
            loadSoldItems();
            username.Items.Add("all cashier sales");
            ComboBox[] items = new ComboBox[] { username };
            pos.loadusername(items[0]);
            dataGridSoldItems.BorderStyle = BorderStyle.None;
            dataGridSoldItems.AlternatingRowsDefaultCellStyle.BackColor = Color.FromArgb(238, 239, 249);
            dataGridSoldItems.CellBorderStyle = DataGridViewCellBorderStyle.SingleHorizontal;
            dataGridSoldItems.DefaultCellStyle.SelectionBackColor = Color.DarkTurquoise;
            dataGridSoldItems.DefaultCellStyle.SelectionForeColor = Color.WhiteSmoke;

            dataGridSoldItems.EnableHeadersVisualStyles = false;
            dataGridSoldItems.ColumnHeadersBorderStyle  = DataGridViewHeaderBorderStyle.None;
            dataGridSoldItems.ColumnHeadersDefaultCellStyle.BackColor = Color.FromArgb(54, 54, 54);
            dataGridSoldItems.ColumnHeadersDefaultCellStyle.ForeColor = Color.White;
            dataGridSoldItems.ColumnHeadersDefaultCellStyle.Padding   = new Padding(0, 6, 0, 6);
        }