|
-
Sep 17th, 2002, 05:14 AM
#1
Thread Starter
Lively Member
Bad text!!! (resolved)
Hello everyone, can some one help me whit this?
I have this kind of text in a text file:
Fri Feb 1 08:16:00 WET 2002
8:16am up 248 day(s), 11 hr(s), 0 users, load average: 0.02, 0.03, 0.03
Fri Feb 1 10:16:00 WET 2002
10:16am up 248 day(s), 13 hr(s), 1 user, load average: 0.00, 0.00, 0.01
Fri Feb 1 13:16:01 WET 2002
When i bring the text to the text box whit this code:
Do
i = i + 1
Input #VarFich, StrOldText
If i = 1 Then
StrHeader = StrOldText
Else
StrNewText = StrNewText & StrOldText & vbNewLine
End If
Loop Until EOF(VarFich)
FrmPrincipal.Text2.Text = StrNewText & vbCrLf
what i can return to de text box is something like this:
8:16am up 248 day(s)
11 hr(s)
0 users
load average: 0.02
0.03
0.03
Fri Feb 1 10:16:00 WET 2002
10:16am up 248 day(s)
13 hr(s)
1 user
load average: 0.00
0.00
0.01
Can someone explain to me why he does this and do not return the text in the exact way like i have in the text file
Last edited by benficaman; Sep 25th, 2002 at 10:39 AM.
-
Sep 17th, 2002, 05:42 AM
#2
Frenzied Member
Use Line Input command
VB Code:
Line Input #VarFich, StrOldText
oh1mie/Vic

-
Sep 17th, 2002, 06:00 AM
#3
It would help us help you if you surrounded your code with [vbcode] [/vbcode] tags.
-
Sep 17th, 2002, 06:10 AM
#4
Fanatic Member
Originally posted by oh1mie
Use Line Input command
VB Code:
Line Input #VarFich, StrOldText
or try
VB Code:
FrmPrincipal.Text2.Text = input(lof(1),1) ' or input(1,lof(1)) cant remember which
that will open the whole file into the variable, or textbox for this case
-
Sep 17th, 2002, 06:16 AM
#5
Thread Starter
Lively Member
sometimes little things like elephants, Thankyou very much men
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|