ACCEPT identifier-1 [ FROM mnemonic-name-1 ] [ END-ACCEPT ] |
ACCEPT identifier-2 FROM { DATE } [END-ACCEPT] { DAY } { CENTURY-DATE } { DATE YYYYMMDD } { CENTURY-DAY } { DAY YYYYDDD } { TIME } { DATE-AND-TIME } { DAY-OF-WEEK } { TERMINAL-INFO } { SYSTEM-INFO } { INPUT STATUS } { ESCAPE KEY } { COMMAND-LINE } { THREAD HANDLE } { WINDOW HANDLE } { CONTROL } { LINE NUMBER } { STANDARD OBJECT Object-Name} { WINDOW OF THREAD Thread-1 } { EXCEPTION STATUS } { DATE-COMPILED } |
ACCEPT [ ( {Identifier-3}, {Identifier-4} ) ] {screen-name-1} {Integer-3 } {Integer-4 } {OMITTED } [ UNTIL Condition-1 ] [ Remaining-Phrases ] [ MOUSE FLAGS mouse-flags ] [ ON {EXCEPTION} [Key-Dest] Imperative-Statement-1 ] {ESCAPE } [ NOT ON {EXCEPTION} Imperative-Statement-2 ] {ESCAPE } [ END-ACCEPT ] |
AT Screen-Loc AT LINE NUMBER {Identifier-3} [CELL ] {Integer-1 } [CELLS ] [PIXEL ] [PIXELS] AT {COLUMN } NUMBER {Identifier-4} [CELL ] {COL } {Integer-2 } [CELLS ] {POSITION} [PIXEL ] {POS } [PIXELS] WITH PROTECTED SIZE Length WITH NO ADVANCING {ERASE} [TO END OF] {LINE } {BLANK} {SCREEN} |
{ERASE} [EOS] {BLANK} [EOL] WITH [NO] {BELL} {BEEP} {UNDERLINE } {UNDERLINED} WITH {BLINKING} {BLINK } {HIGHLIGHT} {HIGH } {BOLD } {LOWLIGHT } {LOW } {STANDARD } {REVERSE-VIDEO} {REVERSE } {REVERSED } SAME WITH {COLOR } Color-Val {COLOUR} {FOREGROUND-COLOR } IS Fg-Color {FOREGROUND-COLOUR} {BACKGROUND-COLOR } IS Bg-Color {BACKGROUND-COLOUR} SCROLL [UP ] [ BY Scrl-Num {LINE } ] [DOWN] {LINES} OUTPUT {JUSTIFIED} {LEFT } {JUST } {RIGHT } {CENTERED} WITH {CONVERSION} {CONVERT } { WITH NO ECHO } { NO-ECHO } { SECURE } { OFF } PROMPT [ CHARACTER IS Prompt-Lit ] { DEFAULT [IS Default] } { UPDATE } ECHO |
{AUTO } {AUTO-SKIP } {AUTOTERMINATE} {TAB } {UPPER} {LOWER} CURSOR Curs-Offset CONTROL Cntrl-String {REQUIRED } {EMPTY-CHECK} {FULL } {LENGTH-CHECK} {ZERO-FILL } {NUMERIC-FILL} CONTROL KEY IN Key-Dest BEFORE TIME Timeout ALLOWING MESSAGES FROM { THREAD Thread-1 } { LAST THREAD } { ANY THREAD } |
ACCEPT Dest-Item FROM SCREEN AT Screen-Loc AT LINE NUMBER Line-Num AT {COLUMN } NUMBER Col-Num {COL } {POSITION} {POS } SIZE Length [END-ACCEPT] |
ACCEPT Dest-Item FROM {CONFIGURATION} Env-Name {ENVIRONMENT } [ ON EXCEPTION Statement-1 ] [ NOT ON EXCEPTION Statement-2 ] [END-ACCEPT] |
ACCEPT {Control-Handle} {CONTROL } [Remaining-Phrases] [ ON {EXCEPTION} [Key-Dest] Statement-1 ] {ESCAPE } [ NOT ON {EXCEPTION} Statement-2 ] {ESCAPE } [END-ACCEPT] |
VALUE IN [MULTIPLE] Value AT Screen-Loc AT LINE NUMBER Line-Num [CELL ] [CELLS ] [PIXEL ] [PIXELS] AT {COLUMN } NUMBER Col-Num [CELL ] {COL } [CELLS ] {POSITION} [PIXEL ] {POS } [PIXELS] WITH {BELL} {BEEP} BEFORE TIME Timeout CONTROL KEY IN Key-Dest ALLOWING MESSAGES FROM { THREAD Thread-1 } { LAST THREAD } { ANY THREAD } |
ACCEPT EVENT BEFORE TIME Timeout ALLOWING MESSAGES FROM { THREAD Thread-1 } { LAST THREAD } { ANY THREAD } [ ON {EXCEPTION} [Key-Dest] Statement-1 ] {ESCAPE } [ NOT ON {EXCEPTION} Statement-2 ] {ESCAPE } [END-ACCEPT] |
ACCEPT value FROM ENVIRONMENT-VALUE [ ON EXCEPTION Statement-1 ] [ NOT ON EXCEPTION Statement-2 ] [END-ACCEPT] |
91 W-TERMINATE | ACCEPT has been terminated by another thread through STOP THREAD statement |
95 W-MESSAGE | message received during ACCEPT with ALLOWING MESSAGES clause |
96 W-EVENT | an event has been raised during the ACCEPT of a graphical screen |
97 W-NO-FIELDS | no input fields are available |
98 W-CONVERSION-ERROR | error during numeric conversion |
99 W-TIMEOUT | time expired during ACCEPT with BEFORE TIME clause |
Character Positions | Contents |
1-2 | The two low-order digits of the year in the Gregorian calendar. |
3-4 | Two numeric characters of the month of the year in the range 01 through 12. |
5-6 | Two numeric characters of the day of the month in the range 01 through 31. |
Character Positions | Contents |
1-4 | Four numeric characters of the year in the Gregorian calendar. |
5-6 | Two numeric characters of the month of the year in the range 01 through 12. |
7-8 | Two numeric characters of the day of the month in the range 01 through 31. |
Character Positions | Contents |
1-2 | The two low-order digits of the year in the Gregorian calendar. |
3-5 | Three numeric characters of the day of the year in the range 001 through 366. |
Character Positions | Contents |
1-4 | Four numeric characters of the year in the Gregorian calendar. |
5-7 | Three numeric characters of the day of the year in the range 001 through 366. |
Character Positions | Contents |
1-2 | Two numeric characters of the hours past midnight in the range 00 through 23. |
3-4 | Two numeric characters of the minutes past the hour in the range 00 through 59. |
5-6 | Two numeric characters of the seconds past the minute in the range 00 through 59 |
7-8 | Two numeric characters of the hundredths of a second past the second in the range 00 through 99. |
Character Positions | Contents |
1-4 | Four numeric characters of the year. |
5-6 | Two numeric characters of the month of the year in the range 01 through 12. |
7-8 | Two numeric characters of the day of the month in the range 01 through 31. |
9-10 | Two numeric characters of the hours past midnight in the range 00 through 23. |
11-12 | Two numeric characters of the minutes past the hour in the range 00 through 59. |
13-14 | Two numeric characters of the seconds past the minute in the range 00 through 59 |
15-16 | Two numeric characters of the hundredths of a second past the second in the range 00 through 99. |
01 terminal-abilities. 03 terminal-name pic x(10). 03 filler pic x. 88 has-reverse value "Y". 03 filler pic x. 88 has-blink value "Y". 03 filler pic x. 88 has-underline value "Y". 03 filler pic x. 88 has-dual-intensity value "Y". 03 filler pic x. 88 has-132-column-mode value "Y". 03 filler pic x. 88 has-color value "Y". 03 filler pic x. 88 has-line-drawing value "Y". 03 number-of-screen-lines pic 9(3). 03 number-of-screen-columns pic 9(3). 03 filler pic x. 88 has-local-printer value "Y". 03 filler pic x. 88 has-visible-attributes value "Y". 03 filler pic x. 88 has-graphical-interface value "Y". 03 usable-screen-height pic x(2) comp-x. 03 usable-screen-width pic x(2) comp-x. 03 physical-screen-height pic x(2) comp-x. 03 physical-screen-width pic x(2) comp-x. 03 filler pic x. 88 is-remote value "Y". 03 client-machine-name pic x(64). 03 filler pic x. 03 client-user-id pic x(20). |
Field | Information |
---|---|
terminal-name | It returns “xterm”. The value can be customized via the configuration property iscobol.terminal.info.name |
has-reverse has-blink has-underline has-dual-intensity has-132-column-mode has-color has-line-drawing has-local-printer has-visible-attributes has-graphical-interface | These flags are set to “Y” if the terminal has the corresponding ability or to “N” otherwise. The values can be customized via the configuration properties |
number-of-screen-lines number-of-screen-columns | These items hold the number of whole lines and columns (respectively) in the current window. If no window has been created, these values are set to the size of the default application window. The values can be customized via the configuration properties iscobol.terminal.info.screen.lines |
usable-screen-height usable-screen-widtht | These items hold the height and width (respecitively) of the usable portion of the user's display device in pixels. The values can be customized via the configuration properties iscobol.terminal.info.screen.usable.height |
physical-screen-height physical-screen-widtht | These items are the same as usable-screen-height and usable-screen-width except that they include the entire screen instead of just the usable portion of the screen. The values can be customized via the configuration properties iscobol.terminal.info.screen.physical.height |
is-remote | This flag is set to “Y” if the program is running in thin client mode, or to “N” if the program is running in stand-alone mode. |
client-machine-name | This item is set when running in thin client mode and it holds the machine name of the client PC. |
client-user-id | This item is set when running in thin client mode and it holds the user name of the client PC. |
01 system-information. 03 operating-system pic x(10). 88 os-is-msdos value "ms-dos". 88 os-is-os2 value "OS/2". 88 os-is-vms values "vms", "vax/vms". 88 os-is-unix value "Linux", "AIX", "HP-UX", "SunOS", "Solaris". 88 os-is-linux value "Linux". 88 os-is-aos value "aos/vs". 88 os-is-windows values "Windows 95", "Windows 98", "Windows Me". 88 os-is-win-nt values "Windows 20", "Windows XP", "Windows Vi", "Windows 7", "WINDOWS", "Windows Se", "Windows 8", "Windows 8.", "Windows 10". 88 os-is-win-family values "Windows 95", "Windows 98", "Windows Me", "Windows 20", "Windows XP", "Windows Vi", "WINDOWS", "Windows 7", "Windows Se", "Windows 8", "Windows 8.", "Windows 10". 88 os-is-amos value "amos". 88 os-is-mpe value "MPE/iX". 88 os-is-mpeix value "MPE/iX". 88 os-is-mac value "Mac OS", "Mac OS X". 03 user-id pic x(12). 03 station-id pic x(12). 03 filler pic x. 88 has-indexed-read-previous value "Y". 03 filler pic x. 88 has-relative-read-previous value "Y". 03 filler pic x. 88 can-test-input-status value "Y". 03 filler pic x. 88 is-multi-tasking value "Y". 03 runtime-version. 05 runtime-major-version pic 99. 05 runtime-minor-version pic 99. 05 runtime-release pic 99. 03 filler pic x. 88 is-plugin value "Y". 03 serial-number pic x(20). 03 filler pic x. 88 has-large-file-support value "Y". 03 filler pic x. 03 filler pic x. 88 is-64-bit value "Y". |
Field | Information |
---|---|
operating-system | This field holds the name of the operating system. The name may be truncated due to the field picture. It’s good practice to reference the corresponding 88 level items in the source. The value can be customized via the configuration property iscobol.os.name. |
user-id | This field holds the system user name. The value can be customized via the configuration property iscobol.user.name. |
station-id | This field is set to spaces by default. The value can be customized via the configuration property iscobol.station |
has-indexed-read-previous has-relative-read-previous can-test-input-status is-multitasking has-large-file-support | These flags are always set to “Y”. |
runtime-version | This field holds the isCOBOL runtime version and release number. |
is-plugin | This flag is always set to “N”. |
serial-number | This field returns the serial number associated to the runtime license. |
is-64-bit | This flag is set to “Y” if the JVM bitness is 64 bit, else it’s set to “N”. |
Screen item | Figurative constant |
Alphabetic Alphanumeric | SPACES |
Alphanumeric Alphanumeric | SPACES |
Alphanumeric-edited Alphanumeric | SPACES |
National National | SPACES |
National-edited National | SPACES |
Numeric | ZEROS |
Numeric-edited | ZEROS |
ERASE, ERASE EOL, ERASE EOS, NO ERASE BEEP, NO BEEP HIGH, LOW, STANDARD, OFF BLINK, NO BLINK REVERSE, NO REVERSE TAB, NO TAB PROMPT, NO PROMPT CONVERT, NO CONVERT UPDATE, NO UPDATE ECHO, NO ECHO UPPER, NO UPPER, LOWER, NO LOWER UNDERLINED, NO UNDERLINE LEFT, RIGHT, CENTERED, NO JUST SAME FCOLOR BCOLOR “GRAPHICS” |
Mouse Action | Value |
---|---|
Allow left button down | 2 |
Allow left button up | 4 |
Allow left button double click | 8 |
Allow middle button down | 16 |
Allow middle button up | 32 |
Allow middle button double click | 64 |
Allow right button down | 128 |
Allow right button up | 256 |
Allow right button double click | 512 |
Allow mouse move | 1024 |
MOUSE FLAGS 2046 |
Mouse Action | Crt Status Value |
---|---|
Mouse moved | 80 |
Left button pushed | 81 |
Left button released | 82 |
Left button double-clicked | 83 |
Middle button pushed | 84 |
Middle button released | 85 |
Middle button double-clicked | 86 |
Right button pushed | 87 |
Right button released | 88 |
Right button double-clicked | 89 |
accept ws-code from console |
*> Accept current date accept my-date from date *> sample value of my-date : 131220 *> Accept current date with 4 digit year accept my-date from date yyyymmdd *> sample value of my-date : 20131220 *> Accept current day of the year accept myday from day yyyyddd *> sample value for myday : 2013335 *> Accept current day and time accept mydatetime from date-and-time *> sample value for mydatetime : 2013121910593228 *> Accept parameters from command line accept all-param from command-line *> See unstring sample to put every parameter word on a separate variable |
working-storage section. 01 window-handle usage handle. 01 cust-values. 05 ws-cust-code pic x(5). 05 ws-cust-name pic x(50). screen section. 01 screen-1. 03 scr-cust-code Entry-Field using ws-cust-code line 3.0 column 21.4 size 12.7 cells lines 3.8 cells id 1 3-d. 03 scr-cust-name Entry-Field using ws-cust-name line 8.7 column 21.4 size 24.5 cells lines 4.6 cells id 2 3-d. 03 scr-lab-1 Label line 2.7 column 4.5 size 13.5 cells lines 3.7 cells id 3 title "Code :". 03 scr-lab-2 Label line 9.3 column 4.5 size 13.5 cells lines 3.7 cells id 4 title "Name :". 03 scr-pb-save Push-Button line 16.4 column 15.7 size 15.5 cells lines 6.4 cells id 5 title "Save". ... |
procedure division. display-and-accept. display standard window background-low screen line 41 screen column 91 size 49.7 lines 24.9 cell width 10 cell height 10 label-offset 20 color 257 modeless title "Customers" handle window-handle. display screen-1. perform until exit-pushed accept screen-1 on exception perform is-screen-1-evaluate-func end-accept end-perform. destroy window-handle. ... |
display "Customer Name : " line 5 col 10 display cust-name line 5 col 30 ... accept tmp-cust-name from screen line 5 col 30 |
*> Get the TEMP environment variable value accept mytemp-dir from environment "temp" *> Get the iscobol.file.index property value accept my-file-index from environment "file.index" *> Get the value of a custom property defined as: *> iscobol.mycustom.location=Location01 accept my-location from environment "mycustom.location" |
working-storage section. 01 window-handle usage handle. 01 cust-values. 05 ws-cust-code pic x(5). 05 ws-cust-name pic x(50). screen section. 01 screen-1. 03 scr-cust-code Entry-Field using ws-cust-code line 3.0 column 21.4 size 12.7 cells lines 3.8 cells id 1 3-d. 03 scr-cust-name Entry-Field using ws-cust-name line 8.7 column 21.4 size 24.5 cells lines 4.6 cells id 2 3-d. 03 scr-lab-1 Label line 2.7 column 4.5 size 13.5 cells lines 3.7 cells id 3 title "Code :". 03 scr-lab-2 Label line 9.3 column 4.5 size 13.5 cells lines 3.7 cells id 4 title "Name :". 03 scr-pb-save Push-Button line 16.4 column 15.7 size 15.5 cells lines 6.4 cells id 5 title "Save". ... |
procedure division. display-and-accept. display standard window background-low screen line 41 screen column 91 size 49.7 lines 24.9 cell width 10 cell height 10 label-offset 20 color 257 modeless title "Customers" handle window-handle. display screen-1. perform until exit-pushed accept scr-cust-code on exception perform is-screen-1-evaluate-func end-accept end-perform. destroy window-handle. ... |
*> ws-event can be a pic 9(9). accept event on exception ws-event continue display message "Event : " ws-event |
display "envfullname" upon environment-name display "Adam Smith" upon environment-value accept f-name from environment-value |