On page 53 of the GCB Programming Manual v1.0 found on the GCB homepage, it shows how to provide variables for a subroutine. I got the general jist of what is meant but I had to go back and read it again and then test it in a program to make sure.
The example shows the following:
subMoveArm(ArmX,ArmY,ArmZ)'code for the subroutine goes hereendsubIntheabovesub,ArmX,ArmYandArmZareallvariables.Ifthecallfromaboveisused,thevariableswillhavethesevaluesatthestartofthesubroutine:ArmX=NewXArmY=NewYArmZ=10Whenthesubroutinehasfinishedrunning,GCBASICwillcopythevaluesbackwherepossible.NewXwillbesettoArmX,andNewYtoArmY.GCBASICwillnotattempttosetthenumber10toArmZ.
While it is nitpicking to say that it should read NewX will be assigned to ArmX, it provides for clear reading. The way it is written, it sounds like NewX is on the left side of the relationship.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
On page 53 of the GCB Programming Manual v1.0 found on the GCB homepage, it shows how to provide variables for a subroutine. I got the general jist of what is meant but I had to go back and read it again and then test it in a program to make sure.
The example shows the following:
While it is nitpicking to say that it should read NewX will be assigned to ArmX, it provides for clear reading. The way it is written, it sounds like NewX is on the left side of the relationship.
Thank you. I have updated the Help File.