Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Why does my Loop end after 11 Loops?
#66
If you expect "X" to be LONG as well you need to say "DIM AS LONG X, Y" instead of "DIM X, Y AS LONG" because it's defining "X" variable as SINGLE. The same with the other line with "DIM".

If you want to assign a bunch of variables in a single "DIM" statement other than SINGLE precision you have to start with "DIM AS (whatever)", otherwise you have to list each variable "AS (whatever)" individually like we had to do before QB64 hit version 1.

With the code supplied, try assigning to "X" involving a regular division rather than integer division, and you'll notice it.
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 mnrvovrfc - 02-13-2023, 06:33 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Exiting sub while inside a loop PhilOfPerth 5 525 12-05-2025, 09:40 AM
Last Post: PhilOfPerth
  Do Loop, Sleep and Mouse Button Dimster 5 599 09-06-2025, 12:57 PM
Last Post: Dimster
  Using modulo to loop through lists fistfullofnails 3 725 09-03-2025, 11:50 PM
Last Post: fistfullofnails
  What is wrong with this for/next loop Helium5793 6 1,159 04-15-2025, 05:11 PM
Last Post: Kernelpanic
  Question on ln in a for/next loop Dimster 13 2,251 09-13-2024, 11:07 PM
Last Post: Kernelpanic

Forum Jump:


Users browsing this thread: 1 Guest(s)