Program Structure; Functions - Monarch 9460 Programmer's Manual

Adk printer
Hide thumbs Also See for 9460:
Table of Contents

Advertisement

P R O G R A M S T R U C T U R E
This chapter discusses program flow control, buffer definitions, and other useful information for
writing your script.
Below is a sample of what a script may look like.
DEFINE TEMPORARY, RegPrice, 6, A
DEFINE TEMPORARY, NewPrice, 6, A
DEFINE PRINTER, PrtRegPrice, 7, A
DEFINE PRINTER, PrtNewPrice, 7, A
FUNCTION Start
BEGIN
END
FUNCTION InitApp
BEGIN
END
.
.
.
F u n c t i o n s
A function is an independent group of statements usually performing a specific task. You execute a
function with the CALL command. See Appendix A, "Sample Script," for a sample script.
Rule:
Each function must have a BEGIN and an END.
FUNCTION function-name
CALL InitApp
CALL GetRegPrice
CALL GetNewPrice
CALL PrintTags
CLEAR Printer
CLEAR RegPrice
.
.
.
BEGIN
.
function-body
.
END
4

Program Structure 4-1

Advertisement

Table of Contents
loading

Table of Contents