Introduction

Language Structure

IB Statements

File System

Comet 32 Runtime

Index

(RJ)

Mnemonic: (RJ)
Hex equivalent: "@0B@"
Discussion: Right justify mark.

The (RJ) control code is used to specify a numeric data entry field. This code places a right justify mark at the current cursor location, taking one screen position and displayed in suppressed background (invisible) mode. It causes data in the following foreground field to be entered from right to left. The right justify mark must be placed immediately before the field for which it is intended.

Characteristics of a right-justified field:

  • Field will accept numeric data only (digits, a decimal point, and a minus sign). Other keys will ring the bell and not be accepted.

  • Cursor remains at the right-hand side of the field (the position for the minus sign) during data entry.

  • Data is entered into the first position to the left of the cursor; the field is shifted left as each new character is entered.

  • Only one decimal point is permitted in the field.

  • The Backspace key deletes characters, one at a time, and shifts the field to the right.

  • The Clear key sets the entire field to foreground blanks.

    Note: As of Comet version 503.79, you can enter a decimal point or any numeric value to clear a right-justified field of any previously-displayed data. In earlier releases of Comet, only numeric values would clear the field.

  • The + and - keys toggle the minus sign at the right-hand side of the field.

  • Other text editing keys are not recognized.
Example:
100 FORMAT   (SB);_                   ! start background
             "ENTER CREDIT LIMIT:";_  ! prompt
             (TM);_                   ! transmit mark
             (RJ);_                   ! right justify mark
             (SF);_                   ! start foreground
             "          ";_           ! blank spaces
             (TM);                    ! transmit mark
             (CH)                     ! cursor home
.
.
.
PRINT (0,100)
INPUT (0) CRLIMIT
This example shows how to use the right justify control code for a numeric data entry field (credit limit). Notice the placement of the transmit marks. Also notice the placement of the foreground blank spaces for the data entry field.