老师,上面好了,下面错误提示找不出原因。
.NET Framework 版本:2.0.50727.3655
Foxtable 版本:2016.7.29.1
错误所在事件:表,费用明细, DataColChanged
详细错误信息:
Exception has been thrown by the target of an invocation.
Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
Select Case e.DataCol.Name
Case "姓名","项目","规格"
Dim n1 As Integer
Dim Lms,py,jps As String
Dim jps1 As New List(Of String)
Lms ="姓名|项目|规格"
For Each py In Lms.split("|")
If py =e.DataCol.Name Then
Exit For
End If
n1+=1
Next
If e.DataRow.Isnull(e.DataCol.Name) Then
py ="@|#|$".split("|")(n1)
Else
py = GetPY(e.DataRow(e.DataCol.Name),True)
End If
jps1.AddRange(e.DataRow("简拼").split("|"))
jps1.Insert(n1,py)
jps1.RemoveAt(n1+1)
For Each py In jps1
jps+=py & "|"
Next
e.DataRow("简拼") = jps.trim("|")
End Select
[此贴子已经被作者于2017/3/2 10:24:59编辑过]