Dim sx() As String = {"鼠","牛","虎","兔","龙","蛇","马","羊","猴","鸡","狗","猪"}
Dim i As Integer = 1
Dim x As Integer = 1
Dim y As Integer = 0
Dim result As String
Do While x < 3600
If CStr(i).Contains("4") = False Then
If x Mod 30 = 0 Then
y = y + 1
End If
If y > 11 Then
y = 0
End If
If y < 12 Then
result &= "NO." & Format(i,"00000000") & "-" & sx(y) & vbcrlf
i = i + 1
End If
x = x + 1
End If
Loop
FileSys.WriteAllText("c:\test.txt",result,False,Encoding.Default)
求指点问题出在哪里?我自己测试了下 好像是 CStr(i).Contains("4") = False 这个条件加上去之后就死,但是好像没问题啊