Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Why does my Loop end after 11 Loops?
#18
Well I solved the problem as any good programmer would do, I scrapped the road I was going down and combined the Recursion Loop with a Do Loop. Where the Seek was struggling it now flies. So basically the structure of the routine it along these lines

Open the file

Recur 

Sub Recur
 Seek #1,1
  Do While Not EOF(1)
  Input the 7 data items
  DataCount = DataCoount +1
  Call to the Subroutine to deal with the 7 data items
  If DataCount = 4000 then exit sub
  recur
end Sub

This is a simplified layout but you get what I mean by combining the Do Loop and Recursion Loop. I'm absolutely sure there is a more elegant way to have done this but as long as I got my 4000 loops I'm a happy camper. I very much appreciate all the wit and humor that comes with the sage advice. Thanks again.
Reply


Messages In This Thread
Why does my Loop end after 11 Loops? - by Dimster - 02-06-2023, 07:08 PM
RE: Why does my Loop end after 11 Loops? - by Dimster - 02-07-2023, 07:42 PM



Users browsing this thread: 11 Guest(s)