Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to format a While... Wend correctly?
#35
Thumbs Up 
(02-29-2024, 11:27 PM)SMcNeill Wrote:
(02-29-2024, 06:33 PM)bplus Wrote: So something else is going on that using count to control stop fixes.

BTW .39 +/-  secs to load dictionary well within acceptable range!
I think the issue you're seeing is from the last line being blank. I don't think it terminates with a chr$(10), so you're never actually advancing to the end of the file.

Add a check for If temp1$ = "" Then Exit Do in there, and you're golden.

Your endless loop is basically start point = 1234567890, end point = 0... then at the end of that loop, start point = end point + 1... so it just starts reading the whole file over and over and over and over and over and over again.

Exit it with a check for that blank line, and you skip that reset to 0. Wink

+1 That sounds so likely and nicely reasoned I don't even want to test and find out it's wrong. ;-))
I've been working on getting v3.12 loaded and copying my 13,994 files and 1051 folders to a backup drive and before that, storing away or dumping 2 months of files and pictures, whew!

Confirmed, I tested by ending loop with this:
Code: (Select All)
Loop Until sp >= Len(temp$) Or ep = 0
b = b + ...
Reply


Messages In This Thread
RE: How to format a While... Wend correctly? - by bplus - 02-29-2024, 11:52 PM



Users browsing this thread: 1 Guest(s)