Recent

Author Topic: For To Do Loop  (Read 987 times)

Allen

  • Newbie
  • Posts: 2
For To Do Loop
« on: August 28, 2018, 07:46:25 pm »
Given the examples in the documentation, I don't understand why the following generates this error code:

FOR i := 1 TO 100 DO
    ptext(i) := ' ';

Error: Illegal expression
Fatal: Syntax error, : ";" expected but "(" found

aducom

  • Full Member
  • ***
  • Posts: 128
    • http://www.aducom.com
Re: For To Do Loop
« Reply #1 on: August 28, 2018, 07:51:20 pm »
Just a wild guess, depending on the type of ptext (array?) it could be
Code: [Select]
   ptext[i]=' ';

Allen

  • Newbie
  • Posts: 2
Re: For To Do Loop
« Reply #2 on: August 28, 2018, 08:40:31 pm »
Yes.  Such a newbie mistake!  :-[

 

TinyPortal © 2005-2018