Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- dataGridView1.ColumnHeadersDefaultCellStyle.BackColor = Color.Black;
- dataGridView1.ColumnHeadersDefaultCellStyle.ForeColor = Color.White;
- dataGridView1.ColumnHeadersDefaultCellStyle.Padding = new Padding(0, 7, 0, 7);
- dataGridView1.ColumnHeadersBorderStyle = DataGridViewHeaderBorderStyle.None;
- dataGridView1.ColumnHeadersDefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter;
- dataGridView1.BackgroundColor = Color.White;
- dataGridView1.AllowUserToAddRows = false;
- dataGridView1.BorderStyle = BorderStyle.None;
- dataGridView1.CellBorderStyle = DataGridViewCellBorderStyle.None;
- dataGridView1.RowHeadersVisible = false;
- dataGridView1.ScrollBars = ScrollBars.Vertical;
- dataGridView1.AllowUserToResizeColumns = false;
- dataGridView1.AllowUserToResizeRows = false;
- dataGridView1.AllowUserToDeleteRows = true;
- dataGridView1.GridColor = SystemColors.Control;
- dataGridView1.EnableHeadersVisualStyles = false;
- dataGridView1.RowsDefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter;
- dataGridView1.RowsDefaultCellStyle.BackColor = Color.White;
- dataGridView1.AlternatingRowsDefaultCellStyle.BackColor = SystemColors.Menu;
- dataGridView1.RowTemplate.Height = 30;
- dataGridView1.RowTemplate.ReadOnly = true;
- dataGridView1.RowsDefaultCellStyle.SelectionBackColor = SystemColors.ScrollBar;
- dataGridView1.RowsDefaultCellStyle.SelectionForeColor = Color.Black;
- dataGridView1.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
- foreach (DataGridViewColumn col in dataGridView1.Columns)
- {
- col.SortMode = DataGridViewColumnSortMode.NotSortable;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement