确实是空格的问题.
Dim str3() As String
If FileSys.FileExists(ProjectPath & "data\pz.ini") Then
Dim Val2 As String = FileSys.ReadAllText(ProjectPath & "data\pz.ini",system.text.encoding.default)
Dim Val3 As String = DecryptText(Val2,"zhujian","zhujian")
Dim str() As String = Val3.Split(vbcrlf)
For i As Integer = 0 To str.length -1
str3 = str(i).split("=")
If str3.length = 2 Then
For Each c As WinForm.Control In e.Form.Controls
If Typeof c Is WinForm.TextBox Then '判断控件是否是文本框
Dim t As WinForm.TextBox = c '使用特定类型的变量引用控件
'MessageBox.Show(t.name & str3(0))
If t.Name.trim()=(str3(0)).trim() Then
MessageBox.show(t.Name)
t.Value = str3(1)
End If
End If
Next
End If
Next
End If