Rockwell-automation 1771-DB BASIC MODULE Manuel d'utilisateur Page 251

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 394
  • Table des matières
  • DEPANNAGE
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 250
Chapter
Call Routines 0–68
12
12 -61
Use this routine to convert a number or numeric variable into a string.
You must use the STRING statement (see page 11 -37) to allocate a
minimum of 14 characters for the string. If the exponent of the value you
want to convert is 100 or greater, you must allocate 15 characters.
Error checking traps string allocation of less than 14 characters only.
Input and Output Arguments
This routine has two input arguments and no output arguments. The first
input argument is the value you want to convert. The second input
argument is the number of the string to receive the value.
Syntax
PUSH
value to be converted
PUSH
number of string to receive the value
CALL
62
Example
>
10 STRING 100,14
>
20 INPUT “ENTER A NUMBER TO CONVERT TO A STRING”,N
>
30 PUSH N
>
40 PUSH 1: REM CONVERT NUMBER TO STRING1
>
50 CALL 62: REM DO THE CONVERSION
>
60 PRINT $(1)
>
70 END
CALL 62: Number to String
Conversion
Vue de la page 250
1 2 ... 246 247 248 249 250 251 252 253 254 255 256 ... 393 394

Commentaires sur ces manuels

Pas de commentaire