Updated: 11/30/2021, 7:00:45 PM
Created: 11/30/2021, 7:00:45 PM
Last Updated By: Jake Tuttle
Read Time: 1 minute(s)
Tags: program profiling
Transfer execution of the script to a specified label, but as a subroutine call. Program execution will continue with the next line after 'gosub' after the subroutine completes execution, usually with a RETURN statement.
where label is the label to which execution should transfer.
An example of use may be as:
gosub loadprog if exitcode ne 0 then exit exitcode # Any other code exit 0 # loadprog: progname = "TESTER " : $VARNAME : " " : portno portno = portno + 1 program loadprog exitcode = $? Return