Shop
OBEX
P1 Docs
P2 Docs
Learn
Events
Can methods be toggled? — Parallax Forums
toggle menu
Categories
Discussions
Sign In
·
Register
Sign In
·
Register
Categories
Discussions
Sign In
·
Register
×
Home
›
Propeller 1
Can methods be toggled?
lardom
Posts:
1,659
2010-02-23 17:44
edited 2010-02-23 18:12
in
Propeller 1
Is it possible to toggle
·
method calls
·
with modulus? I would like to alternate between method "A" and method "B".
Comments
Mike Green
Posts:
23,101
2010-02-23 18:01
edited 2010-02-23 18:01
The only way to do this is to use an IF statement with a Boolean variable like this:
VAR long
switch
....
switch
:=
false
.... IFNOT
switch
A ELSE B NOT
switch
lardom
Posts:
1,659
2010-02-23 18:12
edited 2010-02-23 18:12
Thanks Mike
Sign In
or
Register
to comment.
Comments
VAR long switch .... switch := false .... IFNOT switch A ELSE B NOT switch