private void button17_Click(object sender, EventArgs e) { List <ORDER> Ilk5 = new ORDER().GetOrders(); dataGridView1.DataSource = null; dataGridView1.DataSource = Ilk5.Take(5).ToList(); }
private void button16_Click(object sender, EventArgs e) { List <ORDER> OrdarDate = new ORDER().GetOrders(); dataGridView1.DataSource = null; dataGridView1.DataSource = OrdarDate.Select(x => new { Tarih = x.OrderDate }).ToList(); }
private void button3_Click(object sender, EventArgs e) { List <ORDER> orders = new ORDER().GetOrders(); dataGridView1.DataSource = null; dataGridView1.DataSource = orders; }
private void button19_Click(object sender, EventArgs e) { List <ORDER> YangWang = new ORDER().GetOrders(); dataGridView1.DataSource = null; dataGridView1.DataSource = YangWang.Where(x => x.Customer.ContactName == "Yang Wang") .Select(x => new { x.OrderID, x.Customer.CustomerID, x.OrderDate }) .ToList(); }
private void button18_Click(object sender, EventArgs e) { List <ORDER> Son5 = new ORDER().GetOrders(); dataGridView1.DataSource = null; dataGridView1.DataSource = Son5.OrderByDescending(x => x.OrderID) .Take(5) .Select(x => new { x.OrderID, x.Customer.CustomerID, x.OrderDate }) .ToList(); }
private void button20_Click(object sender, EventArgs e) { List <ORDER> SiparisSayisi = new ORDER().GetOrders(); MessageBox.Show(SiparisSayisi.Count().ToString()); }