private void Form1_Load(object sender, EventArgs e) { QC_Sample_Mix_Table table = new QC_Sample_Mix_Table(); table.LoadData(); foreach (var item in table) { item.CheckItems.LoadDataBySampleMixId(item.Sample_Mix_ID); } this.qCSampleMixBindingSource.DataSource = table; //DbContext db=new DbContext(); //Table<QC_Log> ta= db.GetTable<QC_Log>(); // var a = from log in ta select log; // foreach (var item in a) // { // Console.Write(item.OperateType); // } //double dx = Math.PI / 10; //double result = 0; //for (double x = 0 - Math.PI; x < Math.PI; x+=dx) //{ // result += Math.Cos(x) * Math.Cos(3 * x) * dx; //} //MessageBox.Show(result.ToString()); }