Denso Power Net Terminal BHT-103 Dokumentacja Strona 187

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 577
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 186
179
Calling a user-defined function (
SUB function)
This statement calls a user-defined function specified by functionname. You
may omit
CALL when calling a SUB function.
functionname should be a user-defined function defined by SUB...END SUB
statement.
The number of
realparameters should be equal to that of dummyparame-
ter
s, and the types of the corresponding variables used in those parameters
should be identical.
If you specify a global variable in
realparameter when calling a user-defined
function, the user-defined function cannot update the value of the global variable.
This is because all
realparameters are passed not by address but by value.
(So called "Call-by-value")
Syntax errors:
NOTE
Before any call to a SUB function, you need to place definition of the SUB
function or declaration of the SUB function by using the DECLARE state-
ment in your source program.
Error code and message Meaning
error 3: " missing
No double quote precedes or follows
[drivename:]filename.
error 68: Mismatch
The number of real parameters is not
equal to that of the dummy parameters.
dummyparameter was an integer
variable in defining a function, but
realparameter is a real type in call-
ing the function. (If a dummy parameter
was a real variable in defining a function
and
realparameter is an integer
type in calling, then no error occurs.)
error 71: Syntax error [drivename:]filename is not
enclosed in double quotes.
The function specified by
function-
name
has not been defined.
Przeglądanie stron 186
1 2 ... 182 183 184 185 186 187 188 189 190 191 192 ... 576 577

Komentarze do niniejszej Instrukcji

Brak uwag