home *** CD-ROM | disk | FTP | other *** search
- <<* MSAEDONE.INC *>>
- <<#
-
- procedure EditOne <<*Single Page: (Simple,Bracketed)*>>
- string line1,line2
- begin
- line1 := '@ row,0 SAY "EDIT/VIEW: {E}dit {F}ind {G}oto {L}ocate <Del> "'
- line2 := '@ row+1,12 SAY "{N}ext-record {P}rev-record <Return>"'
- <<*12345678901234567890123456789012345678901234567890*>>
- if ismultials
- line2 := stuff( line2,47,0,'{S}elect ' )
- endif
- if feat(featlabel)
- line2 := stuff( line2,47,0,'{O}utput ' )
- endif
- if Simple
- line1 := ChangePat( line1,'{','(' )
- line2 := ChangePat( line2,'{','(' )
- line1 := ChangePat( line1,'}',')' )
- line2 := ChangePat( line2,'}',')' )
- endif
- genln( line2 ) <<*Gen them in reverse order*>>
- genln( line1 )
- <<*1234567890123456789012345678901234567890*>>
- line1 := 'DO GetKey WITH editchoice,"EFGLNP"+DelRecord+Returnkey'
- if ismultials
- line1 := stuff( line1,34,0,'S' )
- endif
- if feat(featlabel)
- line1 := stuff( line1,33,0,'O' )
- endif
- genln( line1 )
- end EditOne
-
-
- procedure EditPage
- string line1,line2
- begin
- <<* 123456789012345678901234567890123456789012345678901234567890*>>
- line1 := '@ row,0 SAY "EDIT/VIEW: {E}dit {F}ind {G}oto {L}ocate <PgDn> <PgUp> "'
- line2 := '@ row+1,12 SAY "{N}ext-record {P}revious-record <Del> <Return>"'
- if ismultials
- line1 := stuff( line1,60,0,'<Del> ' ) <<*insert*>>
- line2 := stuff( line2,51,5,'{S}elect' ) <<*delete/insert*>>
- endif
- if feat(featlabel)
- line2 := stuff( line2,51,0,'{O}utput ' )
- endif
- if ismultials or feat(featlabel)
- line2 := stuff( line2,38,4,'' ) <<*delete*>>
- endif
- if Simple
- line1 := ChangePat( line1,'{','(' )
- line2 := ChangePat( line2,'{','(' )
- line1 := ChangePat( line1,'}',')' )
- line2 := ChangePat( line2,'}',')' )
- endif
- genln( line2 ) <<*Gen them in reverse order*>>
- genln( line1 )
- <<*1234567890123456789012345678901234567890*>>
- line1 := 'DO GetKey WITH editchoice,"EFGLNP"+DelRecord+PgDn+PgUp+Returnkey'
- if ismultials
- line1 := stuff( line1,34,0,'S' )
- endif
- if feat(featlabel)
- line1 := stuff( line1,33,0,'O' )
- endif
- genln( line1 )
- end EditPage
-
-
- procedure EditOldOne
- string line1,line2
- begin
- line1 := '@ row,0 SAY "EDIT/VIEW: {D}el {E}dit {F}ind {G}oto {L}ocate '
- line2 := '@ row+1,12 SAY "{N}ext-record {P}revious-record '
- if ismultials
- line1 := line1 + ' <Return> "'
- line2 := line2 + '{S}elect"'
- else
- line1 := line1 + '"'
- line2 := line2 + '<Return>"'
- endif
- if Simple
- line1 := ChangePat( line1,'{','(' )
- line2 := ChangePat( line2,'{','(' )
- line1 := ChangePat( line1,'}',')' )
- line2 := ChangePat( line2,'}',')' )
- endif
- genln( line2 ) <<*GEN in reverse order*>>
- genln( line1 )
- <<*1234567890123456789012345678901234567890*>>
- line1 := 'DO GetKey WITH editchoice,"EFGLNP"+DelRecord+Returnkey'
- if ismultials
- line1 := stuff( line1,34,0,'S' )
- endif
- genln( line1 )
- end EditOldOne
-
-
- procedure EditOldPage
- string line1,line2
- begin
- line1 := '@ row,0 SAY "EDIT/VIEW: {D}el {E}dit {F}ind {G}oto {L}ocate {T}urn-page "'
- line2 := '@ row+1,12 SAY "{N}ext-record {P}revious-record <Return>"'
- <<*123456789012345678901234567890123456789012345678901234567890*>>
- if ismultials
- line2 := stuff( line2,51,0,'{S}elect ' )
- line2 := stuff( line2,38,4,'' )
- endif
- if Simple
- line1 := ChangePat( line1,'{','(' )
- line2 := ChangePat( line2,'{','(' )
- line1 := ChangePat( line1,'}',')' )
- line2 := ChangePat( line2,'}',')' )
- endif
- genln( line2 )
- genln( line1 )
- <<*1234567890123456789012345678901234567890*>>
- line1 := 'DO GetKey WITH editchoice,"EFGLNP"+DelRecord+PgDn+Returnkey'
- if ismultials
- line1 := stuff( line1,34,0,'S' )
- endif
- genln( line1 )
- end EditOldPage
-
-
- procedure prompts( row,col : integer; p1,p2,p3,p4,p5,p6,p7 : string )
-
- procedure atprompt( token : string )
- begin
- col := col + val( token[1] ) <<* 1st char is GAP value between items *>>
- if token
- if row = 0
- gen( '@ row,' )
- else
- gen( '@ row+1,' )
- endif
- genln( col,' PROMPT "',substr( token,2,255 ),'"' )
- endif
- col := col + len( token ) - 1
- end atprompt
-
- begin <<*prompts*>>
- atprompt( p1 )
- atprompt( p2 )
- atprompt( p3 )
- atprompt( p4 )
- atprompt( p5 )
- atprompt( p6 )
- atprompt( p7 )
- end prompts
-
-
- procedure EditLiteOne
- <<* 1 2 3 4 5 6
- 0123456789012345678901234567890123456789012345678901234567890
- EDIT/VIEW: Edit Find Goto Locate <Delete> "
- Next-record Prev-record <Return>"
- Next-record Prev-record Select <Return>"
- Next-record Prev-record Output <Return>"
-
- EDIT/VIEW: Edit Find Goto Locate <Del> Output "
- Next-record Prev-record Select <Return>"
- *>>
- string keys
- begin
- if feat(featlabel) and ismultials
- genln( '@ row,0 SAY "EDIT/VIEW: Edit Find Goto Locate <Del> Output"' )
- genln( '@ row+1,12 SAY "Next-record Prev-record Select <Return>"' )
- prompts( 0,12,'0Edit','3Find','3Goto','3Locate','4Del','4Output','' )
- prompts( 1,12,'0Next-record','3Prev-record','3Select','4Return','','','' )
- keys := '"EFGL"+DelRecord+"ONPS"+Returnkey'
- else
- if feat(featlabel)
- genln( '@ row,0 SAY "EDIT/VIEW: Edit Find Goto Locate <Delete>"' )
- prompts( 0,12,'0Edit','3Find','3Goto','3Locate','4Delete','','' )
- genln( '@ row+1,12 SAY "Next-record Prev-record Output <Return>"' )
- prompts( 1,12,'0Next-record','3Prev-record','3Output','4Return','','','' )
- keys := '"EFGL"+DelRecord+"NPO"+Returnkey'
- elsif ismultials
- #>>
- menuchoice = 0
- MSG1 = "Edit"
- MSG2 = "Find"
- MSG3 = "Goto"
- MSG4 = "Locate"
- MSG5 = "Delete"
- MSG6 = "Next-record"
- MSG7 = "Prev-record"
- MSG8 = "Select"
- MSG9 = "Return"
- DO {FILEPREFIX}_MENU WITH 1,41,9,12
- << keys := '"EFGL"+DelRecord+"NPS"+Returnkey'>>
- << else >>
- menuchoice = 0
- MSG1 = "Edit"
- MSG2 = "Find"
- MSG3 = "Goto"
- MSG4 = "Locate"
- MSG5 = "Delete"
- MSG6 = "Next-record"
- MSG7 = "Prev-record"
- MSG8 = "Return"
- DO {FILEPREFIX}_MENU WITH 1,41,8,12
- <<#
- keys := '"EFGL"+DelRecord+"NP"+Returnkey'
- endif
- endif
- #>>
- editchoice=SUBSTR(Returnkey+{keys},menuchoice+1,1)
- <<end EditLiteOne>>
-
-
- <<#
- procedure EditLitePage
- <<* 1 2 3 4 5
- 01234567890123456789012345678901234567890123456789012345
- EDIT/VIEW: Edit Find Goto Locate <Delete> Turn-page
- Next-record Previous-record <Return>
-
- Next-record Prev-record Select <Return>
- Next-record Prev-record Output <Return>
- Next-record Prev-record Output Select <Return>
- *>>
- string keys
- begin
- #>>
- menuchoice = 0
- MSG1 = "Edit"
- MSG2 = "Find"
- MSG3 = "Goto"
- MSG4 = "Locate"
- MSG5 = "Delete"
- MSG6 = "Turn-page"
- <<#
- if feat(featlabel) and ismultials
- genln( '@ row+1,12 SAY "Next-record Prev-record Output Select <Return>"' )
- prompts( 1,12,'0Next-record','3Prev-record','3Output','3Select','4Return','','' )
-
- keys := '"EFGL"+DelRecord+PgDn+"NPOS"+Returnkey'
- elsif feat(featlabel)
- genln( '@ row+1,12 SAY "Next-record Prev-record Output <Return>"' )
- prompts( 1,12,'0Next-record','3Prev-record','3Output','4Return','','','' )
-
- keys := '"EFGL"+DelRecord+PgDn+"NPO"+Returnkey'
- elsif ismultials
- genln( '@ row+1,12 SAY "Next-record Prev-record Select <Return>"' )
- prompts( 1,12,'0Next-record','3Prev-record','3Select','4Return','','','' )
-
- keys := '"EFGL"+DelRecord+PgDn+"NPS"+Returnkey'>>
- else
- #>>
- <<* FOR MULTI PAGE RECORDS *>>
- MSG7 = "Next-record"
- MSG8 = "Prev-record"
- MSG9 = "Return"
- DO {FILEPREFIX}_MENU WITH 1,41,9,12
- << keys := '"EFGL"+DelRecord+PgDn+"NP"+Returnkey'>>
- << endif>>
-
- <<* NOT NEEDED -- MENU TO menuchoice *>>
- editchoice=SUBSTR(Returnkey+{keys},menuchoice+1,1)
- <<end EditLitePage>>
-
- <<* EOF: MSAEDONE.INC *>>