'//在4楼的基础上增加下品种判断:
Dim dt_jilu As DataTable = DataTables("进鸡记录")
Dim dt_biaozhun As DataTable = DataTables("饲养标准")
Dim dt_yusuan As DataTable = DataTables("生产预算")
dt_yusuan.StopRedraw()
dt_yusuan.DataRows.Clear
For Each dr_jilu As DataRow In dt_jilu.DataRows
Dim count As Integer = 0
For Each dr_biaozhun As DataRow In dt_biaozhun.Select("品种 = '"& dr_jilu("品种") &"'")
For i As Integer = 1 To 7
Dim ndr As DataRow = dt_yusuan.AddNew()
ndr("日期") = dr_jilu("日期").AddDays(count)
ndr("批次") = dr_jilu("批次")
ndr("品种") = dr_jilu("品种")
ndr("日龄") = count + 1
ndr("周龄") = count \ 7 + 1
ndr("进栏公鸡") = dr_jilu("进栏公鸡")
ndr("进栏母鸡") = dr_jilu("进栏母鸡")
ndr("公鸡采食量") = dr_biaozhun("公鸡采食量")
ndr("母鸡采食量") = dr_biaozhun("母鸡采食量")
ndr("产蛋率") = dr_biaozhun("产蛋率")
count += 1
Next
Next
Next
dt_yusuan.ResumeRedraw()