Dim Cols1() As String = {"工段","工序","流程"}
Dim Cols2() As String = {"工段","工序","流程"}
For Each dr3 As DataRow In DataTables("产品生产流程").Select("[名称] = '" & dr2("流程") & "'")
Dim dr4 As DataRow = DataTables("生产计划标准").AddNew()
For i As Integer = 0 To Cols1.Length -1
dr4(Cols2(i)) = dr3(Cols1(i))
dr4("产品编号")=r("产品编号")
dr4("规格型号")=r("规格型号")
dr4("图号")=r("公司图号")
dr4("拟制人")=_UserName
dr4("日期")=Date.Today()
Next
Next
以上代码运行后,自动添加了“产品生产流程”中的所有流程,但是添加的顺序有点乱,如果按照"_Identify"的顺序添加上去,应该如何修改上面的代码。