Q
quixote
I am having problems with the following loop. For some
reason after I go to a record the VbNewLine doesn't work(I
also tried VbCrLf). Also when I try to loop to the next
record i was still equal to fields.count-1, that is why I
have i=0 before I loop again. Every loop just seems to
concatenate the first record over and over.
Do While Not rs.EOF()
'create the tilde delimited line
For i = 0 To rs.Fields.Count - 1
textline = textline & rs.Fields(i) & "~"
Next
'get rid of last tilde
textline = Left(textline, Len(textline) - 1)
'print the line and move down to next line
Print #1, textline; vbNewLine
i = 0
Loop
Close #1
.....thanks
reason after I go to a record the VbNewLine doesn't work(I
also tried VbCrLf). Also when I try to loop to the next
record i was still equal to fields.count-1, that is why I
have i=0 before I loop again. Every loop just seems to
concatenate the first record over and over.
Do While Not rs.EOF()
'create the tilde delimited line
For i = 0 To rs.Fields.Count - 1
textline = textline & rs.Fields(i) & "~"
Next
'get rid of last tilde
textline = Left(textline, Len(textline) - 1)
'print the line and move down to next line
Print #1, textline; vbNewLine
i = 0
Loop
Close #1
.....thanks