Mitsubishi MELFA CR1D Instruction Manual page 214

Table of Contents

Advertisement

4MELFA-BASIC IV
FPrm (FPRM)
[Function]
Defines the order of the arguments, the type, and number for the main program that uses arguments in a
sub program (i.e., when the host program uses another program with CALL P).
[Format]
FPrm[]<Dummy Argument> [,<Dummy Argument>] ...
[Terminology]
<Dummy Argument>
[Reference Program]
<Main program>
1 M1=1
2 P2=P_Curr
3 P3=P100
4 CallP "100",M1,P2,P3
<Sub program "100">
1 FPrm M1,P1,P2
2 If M1=1 Then GoTo 40
3 Mov P1
4 Mvs P2
5 End
[Explanation]
(1) FPrm is unnecessary if there are no arguments in the sub program that is called up.
(2) An error occur when the type or number is different between the argument of CallP and the dummy argu-
ment that defined by FPrm.
(3) It is not possible to pass the processing result of a sub program to a main program by assigning it in an
argument.
To use the processing result of a sub program in a main program, pass the values using external vari-
ables.
[Related instructions]
CallP (Call P)
4-201 Detailed explanation of command words
The variable in the sub program that is transferred to the main statement when
executed. All variables can be used. Up to 16 variables may be used.
' It can be described like "CallP "100", 1, P_Curr, P100" also.
' Return to the main program.

Advertisement

Table of Contents
loading

This manual is also suitable for:

Melfa cr2dMelfa cr3d

Table of Contents