HP 3000 Manuals

NLNUMSPEC [ MPE/iX Intrinsics Reference Manual ] MPE/iX 5.0 Documentation


MPE/iX Intrinsics Reference Manual

NLNUMSPEC 

NM and CM callable.

Returns the information needed for formatting and converting numbers.  It
combines several calls to NLINFO to simplify the use of native language
formatting.  By calling NLNUMSPEC once, and passing the obtained
information to NLFMTNUM and NLCONVNUM, implicit calls to NLNUMSPEC from
NLFMTNUM and NLCONVNUM are avoided and performance is improved.

Syntax 
_______________________________________
|                                     |
|                 I16V    U16A  U16A  |
|     NLNUMSPEC(langnum,string,error);|
_______________________________________

            

Parameters 

langnum               16-bit signed integer by value (required) 

                      Contains the language ID number.

string                16-bit unsigned integer array (required) 

                      Contains >= 60 bytes, where the following
                      information is returned:

                        Byte(s)   Meaning 

                         00-01    Language identification number (integer)

                         02-03    Alternate digit indicator (integer)

                                  0    No alternate digits exist
                                  1    Alternate digits exist

                         04-05    Language direction indicator (integer)

                                  0    Language is left-to-right
                                  1    Language is right-to-left

                         06-07    Alternate digit range (0,9)

                          08      Decimal separator (ASCII-digits)

                          09      Decimal separator (alternate-digits)

                          10      Thousands separator (ASCII-digits)

                          11      Thousands separator (alternate-digits)

                          12      '+' (alternate-digits)

                          13      '-' (alternate-digits)

                          14      Right-to-left space

                          15      Reserved for the operating system

          Table 4-26.  (cont.) 

                        Byte(s)   Meaning 

                         16-17    Currency place (integer)

                                  0    Currency symbol
                                  1    Currency symbol succeeds the number
                                  2    Currency symbol replaces the decimal separator
                                  3    Currency symbol precedes the sign

                         18-19    Length of currency symbol (integer), includes spaces

                         20-37    Currency symbol, includes spaces

                         38-59    Reserved for the operating system

error                 16-bit unsigned integer array (required) 

                      Returns two elements:  the first element is the
                      error number; the second element is reserved and
                      always returns 0.  The possible error number values
                      are:

                         Value    Meaning 

                           0      Successful

                           1      *NLS not installed

                           2      *Specified language not configured

                           3      Invalid string

                           5      *NLS internal error

                           6      *NLS internal error

                      * Do not apply to calls with langnum equal to 0
                      (NATIVE3000/XL).

Operation Notes 

Split-stack calls are not permitted.

The intrinsic combines NLINFO calls with itemnums 9, 10, 31, 32, and 33.
The information is formatted where needed (for example, any spaces in the
currency symbol/name are included).  The currency symbol/name is the
shortest nonblank descriptor, as returned from NLINFO itemnums 10 and 31.

This intrinsic does not provide any information not obtainable with
NLINFO. It is included for the convenience of the NLS user.  For
efficiency, the user of this intrinsic calls it only once, saves the
result, and calls NLFMTNUM and/or NLCONVNUM multiple times.

Related Information 

Intrinsics            NLCONVNUM, NLFMTNUM

Commands              None

Manuals               Native Language Programmer's Guide (32650-90022)



MPE/iX 5.0 Documentation