-
Notifications
You must be signed in to change notification settings - Fork 0
/
Main.cs
33 lines (29 loc) · 1.06 KB
/
Main.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using DevExpress.XtraEditors;
using System.Drawing.Drawing2D;
using DevExpress.XtraGrid.Views.Grid;
namespace DXSample {
public partial class Main: XtraForm {
public Main() {
InitializeComponent();
}
private void Main_Load(object sender, EventArgs e) {
// TODO: This line of code loads data into the 'nwindDataSet.Customers' table. You can move, or remove it, as needed.
this.customersTableAdapter.Fill(this.nwindDataSet.Customers);
}
private void myGridView1_CustomDrawGridLine(object sender, CustomDrawLineEventArgs e) {
if(e.CellInfo != null)
e.Appearance.BackColor = e.CellInfo.RowHandle % 2 == 0 ? Color.BlueViolet : Color.DarkOrange;
else {
e.Cache.FillRectangle(Brushes.CadetBlue, e.Bounds);
e.Handled = true;
}
}
}
}