IonicWind Software

IWBasic => General Questions => Topic started by: Brian on December 08, 2014, 11:52:49 AM

Title: Puzzled...
Post by: Brian on December 08, 2014, 11:52:49 AM
Hi,

While trying to compile an old .IBA source file (not .IWB) I came across this line:

FOR ii = rmax TO 0 #-1

Of course, IWB didn't like the hash, but taking it out causes the program not to work correctly
What is the meaning of the hash (de-referencing?), and how do I get round it?

Brian
Title: Re: Puzzled...
Post by: LarryMc on December 08, 2014, 12:54:50 PM
I have never seen that before.
The proper syntax would be
FOR ii = rmax TO 0 STEP -1
Title: Re: Puzzled...
Post by: GWS on December 08, 2014, 01:11:08 PM
Hi,

The #number was an old form of STEP and could be used interchangeably  ;D

FOR counter = 1 TO 20 #2

or alternatively, FOR counter = 1 TO 20 STEP 2

Even the user guide got a little confused, referring to SKIP rather than STEP.

Graham
Title: Re: Puzzled...
Post by: Brian on December 08, 2014, 03:17:22 PM
Thanks to Larry and Graham for clearing that one up - I eventually settled for STEP myself,
although I have never seen the hash used like that before

Brian