con = new SqlConnection("Initial Catalog=customer;data source=arun;Integrated Security=SSPI"); da = new SqlDataAdapter("Select * from dayprogram1", con); da1 = new SqlDataAdapter("Select * from TimeAllocate where code=100", con); ds = new DataSet(); da.Fill(ds, "dayprogram1"); da1.Fill(ds,"TimeAllocate"); dr = new DataRelation("parent", ds.Tables["dayprogram1"].Columns["code"], ds.Tables["TimeAllocate"].Columns["code"]); ds.Relations.Add(dr); dr.ChildKeyConstraint.DeleteRule = Rule.None; dr.ChildKeyConstraint.UpdateRule = Rule.None; loaddata();
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)