textbox2的内容如下:
登记时间: 否;入院时间:否;开始时间: 无;截止时间: 无;患者种类: 无;统计项目: 性别.
登记时间:是;入院时间:否;开始时间: 无;截止时间: 无;患者种类: 失访患者(登记时间);统计项目: 性别.
点击“统计”后,出现运行错误,代码如下:
Dim str As String= e.Form.Controls("TextBox2").value
Dim n As Integer
Dim strs() As String
strs =str.replace(vbcr,"").Split(vblf)
n=strs.Length
Dim i As Integer
Dim dt(i) As fxDataSource
For i = 0 To n-1
If strs(i)>"" Then
Dim s() As String =strs(i).Split(";")
For j As Integer = 0 To s(j).length-1
If s(j) > "" Then
MessageBox.Show(s(j),"提示")
End If
Next
End If
Next
错误提示如下,在出现第一段后面,第二段前面。

此主题相关图片如下:360软件小助手截图20131221150249.jpg

[此贴子已经被作者于2013-12-21 15:03:34编辑过]