调试技巧:http://www.foxtable.com/webhelp/scr/1485.htm,看执行到哪里出错
抄代码之前先花点时间理解一下,如果看不懂,那么就发帖问一问。
几个问题
1、使用Current没有判断是否有值
2、有些属性可能会识别不到,请判断json是否有值再使用,既然别人的例子有这个判断,一般都不会是多余的
If jo("words_result")("公民身份号码") IsNot Nothing Then sbu.AppendLine( "--公民身份号码:" & jo("words_result")("公民身份号码")("words").ToString)
……
Dim gSf1 As String =jo("words_result")("公民身份号码")("words").ToString
3、这个判断【If File.EndsWith("2.jpg") Or File.EndsWith("2.JPG") Then】是在这个if里面的【If File.EndsWith("1.jpg") Or File.EndsWith("1.JPG") Then 】,这个判断里面的代码永远都不可能执行到。
4、至于闪退估计还是和下面的代码导致触发的其它事件执行有关
Dim idx As Integer = Tables("员工信息_员工信息").position
If idx <> 0 Then
Tables("员工信息_员工信息").position = 0
Tables("员工信息_员工信息").position = idx
Else
Tables("员工信息_员工信息").position += 1
Tables("员工信息_员工信息").position = idx
End If