j=0去掉 text1.text=text1.text & vbcrlf & i(j) 你的代码完全可以简化如下: Private Sub Cmd1_Click() on error resume next dim ReadText as string Open App.Path & "\in.txt" For Input As #1 do while not eof(1) line input #1,ReadText text1.text=text1.text & vbcrlf & ReadText loop Close #1 End Sub 我可以代写,需要menoy.
Dim i As Integer Private Sub Cmd1_Click() Dim j As Integer Open App.Path & "\in.txt" For Input As #1 For j = 1 To 100 Input #1, i Text1.Text = Text1.Text & i & Space(5) Next Close #1 End Sub 这种东西都能要钱,不是吧
不会显示全部
Text1.Text 是一字符串。要求:同时在文本框中显示出来。
所以掉后面的“Text1.Text &”就不行
text1.text=text1.text & vbcrlf & i(j)
你的代码完全可以简化如下:
Private Sub Cmd1_Click()
on error resume next
dim ReadText as string
Open App.Path & "\in.txt" For Input As #1
do while not eof(1)
line input #1,ReadText
text1.text=text1.text & vbcrlf & ReadText
loop
Close #1
End Sub
我可以代写,需要menoy.
Private Sub Cmd1_Click()
Dim j As Integer
Open App.Path & "\in.txt" For Input As #1
For j = 1 To 100
Input #1, i
Text1.Text = Text1.Text & i & Space(5)
Next
Close #1
End Sub
这种东西都能要钱,不是吧