База данных страховой компании

и выплат на 1 ' | & 'работника страховой организации') . . EJECT CODE OPEN(SCREEN) !OPEN THE MENU SCREEN SETCURSOR !TURN OFF ANY CURSOR MENU_FIELD" = '' !START MENU WITH FIRST ITEM LOOP !LOOP UNTIL USER EXITS ALERT !TURN OFF ALL ALERTED KEYS ALERT(REJECT_KEY) !ALERT SCREEN REJECT KEY ALERT(ACCEPT_KEY) !ALERT SCREEN ACCEPT KEY ALERT(F2_KEY) !ALERT HOT KEY ACCEPT !READ A FIELD OR MENU CHOICE IF KEYCODE() = F2_KEY !ON HOT KEY UPDATE(?) ! RETRIEVE FIELD SAVACTN# = ACTION ! SAVE ACTION S ! CALL HOT KEY PROCEDURE ACTION = SAVACTN# ! RESTORE ACTION SELECT(?) ! DO SAME FIELD AGAIN CYCLE ! AND LOOP AGAIN . IF KEYCODE() = REJECT_KEY THEN RETURN. !RETURN ON SCREEN REJECT IF KEYCODE() = ACCEPT_KEY !ON SCREEN ACCEPT KEY UPDATE ! MOVE ALL FIELDS FROM SCREEN SELECT(?) ! START WITH CURRENT FIELD SELECT ! EDIT ALL FIELDS CYCLE ! GO TO TOP OF LOOP . ! CASE FIELD() !JUMP TO FIELD EDIT ROUTINE OF ?FIRST_FIELD !FROM THE FIRST FIELD IF KEYCODE() = ESC_KEY THEN RETURN. ! RETURN ON ESC KEY OF ?PRE_MENU !PRE MENU FIELD CONDITION IF KEYCODE() = ESC_KEY ! BACKING UP? SELECT(?-1) ! SELECT PREVIOUS FIELD ELSE ! GOING FORWARD SELECT(?+1) ! SELECT MENU FIELD . OF ?MENU_FIELD" !FROM THE MENU FIELD EXECUTE CHOICE() ! CALL THE SELECTED PROCEDURE AT1 ! AT2 ! AT3 ! . . .

(ant2)

MEMBER('ANT') R PROCEDURE

SCREEN SCREEN PRE(SCR),WINDOW(1,3),AT(9,77),HUE(0,2) ENTRY,USE(?FIRST_FIELD) ROW(1,1) ENTRY,USE(MEM:NR) NR COL(1) STRING(@n3),HUE(7,7) ENTRY,USE(?LAST_FIELD) .

EJECT CODE OPEN(SCREEN) !OPEN THE SCREEN SETCURSOR !TURN OFF ANY CURSOR DISPLAY !DISPLAY THE FIELDS LOOP !LOOP THRU ALL THE FIELDS SCR:NR = MEM:NR ALERT !RESET ALERTED KEYS ALERT(ACCEPT_KEY) !ALERT SCREEN ACCEPT KEY ALERT(REJECT_KEY) !ALERT SCREEN REJECT KEY ACCEPT !READ A FIELD IF KEYCODE() = REJECT_KEY THEN RETURN. !RETURN ON SCREEN REJECT KEY

IF KEYCODE() = ACCEPT_KEY !ON SCREEN ACCEPT KEY UPDATE ! MOVE ALL FIELDS FROM SCREEN SELECT(?) ! START WITH CURRENT FIELD SELECT ! EDIT ALL FIELDS CYCLE ! GO TO TOP OF LOOP . !

CASE FIELD() !JUMP TO FIELD EDIT ROUTINE OF ?FIRST_FIELD !FROM THE FIRST FIELD IF KEYCODE() = ESC_KEY THEN RETURN. ! RETURN ON ESC KEY

OF ?MEM:NR XRE:NREGION = MEM:NR !MOVE RELATED FIELDS GET(XREG,XRE:K1) !READ THE RECORD ACTION# = ACTION !SAVE ACTION ACTION = 4 !REQUEST TABLE LOOKUP REG !CALL LOOKUP PROCEDURE IF ACTION !NO SELECTION WAS MADE SELECT(?MEM:NR-1) ! BACK UP ONE FIELD ACTION = ACTION# ! RESTORE ACTION CYCLE ! GO TO TOP OF LOOP . SCR:NR = XRE:NREGION !DISPLAY LOOKUP FIELD MEM:NR = XRE:NREGION !MOVE LOOKUP FIELD DISPLAY(?MEM:NR) !AND DISPLAY IT ACTION = ACTION# !RESTORE ACTION MEN2

OF ?LAST_FIELD !FROM THE LAST FIELD ACTION = 0 ! SET ACTION TO COMPLETE RETURN ! AND RETURN TO CALLER . .

(ant3)

MEMBER('ANT') REG PROCEDURE SCREEN SCREEN PRE(SCR),WINDOW(25,39),AT(1,42),HUE(8,7) ROW(2,9) PAINT(1,19),HUE(0,7) ROW(1,1) STRING('+-{37}+') ROW(2,1) REPEAT(2);STRING('¦<0{37}>¦') . ROW(4,1) STRING('¦') ROW(5,1) REPEAT(20);STRING('¦<0{37}>¦') . ROW(25,1) STRING('+-{37}+') ROW(2,12) STRING('<130>выберите<0>регион') ROW(4,39) STRING('¦') ENTRY,USE(?FIRST_FIELD) ENTRY,USE(?PRE_POINT) REPEAT(21),EVERY(1),INDEX(NDX) COL(2) POINT(1,37),USE(?POINT),ESC(?-1) IREG COL(3) STRING(35) . . NDX BYTE !REPEAT INDEX FOR POINT AREA ROW BYTE !ACTUAL ROW OF SCROLL AREA COL BYTE !ACTUAL COLUMN OF SCROLL AREA COUNT BYTE(21) !NUMBER OF ITEMS TO SCROLL ROWS BYTE(21) !NUMBER OF ROWS TO SCROLL COLS BYTE(37) !NUMBER OF COLUMNS TO SCROLL FOUND BYTE !RECORD FOUND FLAG NEWPTR LONG !POINTER TO NEW RECORD TABLE TABLE,PRE(TBL) !TABLE OF RECORD DATA PTR LONG ! POINTER TO FILE RECORD IREG STRING(35) NREG SHORT . EJECT CODE ACTION# = ACTION !SAVE ACTION OPEN(SCREEN) !OPEN THE SCREEN SETCURSOR !TURN OFF ANY CURSOR TBL:PTR = 1 !START AT TABLE ENTRY NDX = 1 !PUT SELECTOR BAR ON TOP ITEM ROW = ROW(?POINT) !REMEMBER TOP ROW AND COL = COL(?POINT) !LEFT COLUMN OF SCROLL AREA RECORDS# = TRUE !INITIALIZE RECORDS FLAG CACHE(XRE:K,.25) !CACHE KEY FILE IF ACTION = 4 ! TABLE LOOKUP REQUEST NEWPTR = POINTER(XREG) ! SET POINTER TO RECORD IF NOT NEWPTR ! RECORD NOT PASSED TO TABLE SET(XRE:K,XRE:K) ! POSITION TO CLOSEST RECORD NEXT(XREG) ! READ RECORD NEWPTR = POINTER(XREG) ! SET POINTER . DO FIND_RECORD ! POSITION FILE ELSE NDX = 1 ! PUT SELECTOR BAR ON TOP ITEM DO FIRST_PAGE ! BUILD MEMORY TABLE OF KEYS . RECORDS# = TRUE ! ASSUME THERE ARE RECORDS LOOP !LOOP UNTIL USER EXITS ACTION = ACTION# !RESTORE ACTION ALERT !RESET ALERTED KEYS ALERT(REJECT_KEY) !ALERT SCREEN REJECT KEY ALERT(ACCEPT_KEY) !ALERT SCREEN ACCEPT KEY ACCEPT !READ A FIELD IF KEYCODE() = REJECT_KEY THEN BREAK. !RETURN ON SCREEN REJECT KEY IF KEYCODE() = ACCEPT_KEY | !ON SCREEN ACCEPT KEY AND FIELD() <> ?POINT !BUT NOT ON THE POINT FIELD UPDATE ! MOVE ALL FIELDS FROM SCREEN SELECT(?) ! START WITH CURRENT FIELD SELECT ! EDIT ALL FIELDS CYCLE ! GO TO TOP OF LOOP . CASE FIELD() !JUMP TO FIELD EDIT ROUTINE OF ?FIRST_FIELD !FROM THE FIRST FIELD IF KEYCODE() = ESC_KEY | ! RETURN ON ESC KEY OR RECORDS# = FALSEб ! OR NO RECORDS BREAK !EXIT PROCEDURE . OF ?PRE_POINT!PRE POINT FIELD CONDITION IF KEYCODE() = ESC_KEY! BACKING UP? SELECT(?-1) !SELECT PREVIOUS FIELD ELSE ! GOING FORWARD SELECT(?POINT) !SELECT MENU FIELD . OF ?POINT !PROCESS THE POINT FIELD IF RECORDS(TABLE) = 0 !IF THERE ARE NO RECORDS CLEAR(XRE:RECORD) ! CLEAR RECORD AREA ACTION = 1 ! SET ACTION TO ADD GET(XREG,0) ! CLEAR PENDING RECORD NEWPTR = POINTER(XREG) !SET POINTER TO NEW RECORD DO FIRST_PAGE ! DISPLAY THE FIRST PAGE IF RECORDS(TABLE) = 0 ! IF THERE AREN'T ANY RECORDS RECORDS# = FALSE !INDICATE NO RECORDS SELECT(?PRE_POINT-1) !SELECT THE PRIOR FIELD . CYCLE !AND LOOP AGAIN . CASE KEYCODE() !PROCESS THE KEYSTROKE OF INS_KEY !INS KEY CLEAR(XRE:RECORD) ! CLEAR RECORD AREA ACTION = 1 ! SET ACTION TO ADD GET(XREG,0) ! CLEAR PENDING RECORD IF ~ACTION ! IF RECORD WAS ADDED NEWPTR = POINTER(XREG) !SET POINTER TO NEW RECORD DO FIND_RECORD !POSITION IN FILE . OF ENTER_KEY !ENTER KEY OROF ACCEPT_KEY !CTRL-ENTER KEY DO GET_RECORD ! GET THE SELECTED RECORD IF ACTION = 4 AND KEYCODE() = ENTER_KEY !IF THIS IS A LOOKUP REQUEST ACTION = 0 !SET ACTION TO COMPLETE BREAK !AND RETURN TO CALLER . IF ~ERROR() ! IF RECORD IS STILL THERE ACTION = 2 !SET ACTION TO CHANGE IF ACTION THEN CYCLE. !IF SUCCESSFUL RE-DISPLAY . NEWPTR = POINTER(XREG) !SET POINTER TO NEW RECORD DO FIND_RECORD !POSITION IN FILE OF DEL_KEY !DEL KEY DO GET_RECORD ! READ THE SELECTED RECORD IF ~ERROR() ! IF RECORD IS STILL THERE ACTION = 3 !SET ACTION TO DELETE IF ~ACTION !IF SUCCESSFUL N# = NDX ! SAVE POINT INDEX DO SAME_PAGE ! RE-DISPLAY NDX = N# ! RESTORE POINT INDEX . . OF DOWN_KEY !DOWN ARROW KEY DO SET_NEXT ! POINT TO NEXT RECORD DO FILL_NEXT ! FILL A TABLE ENTRY IF FOUND ! FOUND A NEW RECORD SCROLL(ROW,COL,ROW

скачать реферат
1 2 3 4 5 6 ...    последняя
Рефераты / Страхование /