/**************************************************************************\ $VER: Logon Activities, v3.4 by Dotoran (2-Jul-94) \**************************************************************************/ options results;signal on SYNTAX;signal on ERROR;signal on IOERR tr=transmit;se=sendstring;gc=getchar;gu=getuser;gs=getscratch;mg=maygetchar pver='$VER 3.4';call SETUP;call READACTS;call READUSER;newuser=0 AUTO: /* Run ALL Activities found in Menu # 0 IMMEDIATELY! */ if tot.0>0 & last='ACT' then do;se 'f1na'c7'Run 'c5'"'c8'Auto'c5'" ' se c11'Activities 'c7'Now? 'c5'['c8'No'c5']'c7': 'c8;gc;a=result if a~='Y' then do;tr 'No.';signal START;end;else tr 'Yes!';end if tot.0>0 then do;do i=1 to tot.0;item=act.0.i;if act.item='[DEL]' then iterate i changewhere name.item;old=result;if more.item=1 then call NOMORE;se 'f1@'more.item*4''load.item'}';call CHECK if pause.item=1 then se 'n1'pausebar;if more.item=1 then call MORE;changewhere old;end i;end START:;tr 'f1@4'c5||sp||center(' (Menu #'menu')',37)'n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'c3||c4||center(menu.menu,36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0';mflag=0;if ansi='ON' then signal START0 if help='ON' then tr sp||c5' Press 'c11'"'c9'H'c11'" 'c5'to turn 'c9'HELP 'c5'off.n1';else tr if tot.menu=0 then tr sp||c5' No Activities in this Menu' do i=1 to tot.menu;c=c7;if i//2=0 then c=c8 item=act.menu.i;name=name.item if name.item='[DEL]' then name=c2'['c3||c4' DELETED ITEM z0'c2']' tr sp||in||c5||i||c6'> 'c||name;end i;do 9-tot.menu;tr;end;m1='';m2='';m3='' if menu 'c'Next Menu';end if menu>0 then do;m2=c9'P'c6'/' tr sp||in||c9'P'c10'> 'c12'Previous Menu';end tr sp||in||c9'H'c10'> 'c11'Help Mode 'c5'['c9||help||c5'] ' tr sp||in||c9'U'c10'> 'c12'Use Another Menu' tr sp||in||c9'M'c10'> 'c11'Maintenance Menu' tr sp||in||c9'Q'c10'> 'c12'Quit to Main>n1' m=left('123456789',tot.menu);if tot.menu=1 then m3=c5'1'c6'/' if tot.menu>1 then m3=c5'1'c6'-'c5||tot.menu||c6'/' tr sp||c13'Activity? 'c6'('m3||m1||m2||c9'H'c6'/'c9'U'c6'/'c9'M'c6'/'c8'['c9'Q'c8']'c6')' if useansi=1 then se sp||c5'ESC 'c6'= 'c5'Ansi 'c6'Menus'c13': ';else se sp||c6'Your Command'c13': ';signal START2 START0:;if tot.menu=0 then mf1=10;do i=1 to tot.menu;c=c7' ' if i%2=i/2 then c=c8' ';if i=mf1 then c='z4cf*';item=act.menu.i;it1.i=name.item tr '['i+5';31H'c||it1.i'z0';end i;if tot.menu<9 then do i=tot.menu+1 to 9;it1.i='';end do i=10 to 13;c=c12' ';if i%2=i/2 then c=c11' ';if i=mf1 then c='z4cf*' tr '['i+6';31H'c||it1.i'z0';if i=10 then tr ''c5'['c9||help||c5'] ';end i tr ''c7'Up'c11'/'c7'Down 'c11'= 'c7'Choose Item'c11', 'c8'Left'c11'/'c8'Right 'c11'= 'c8'Change Menu'c11',' tr ' 'c9'ENTER 'c11'= 'c9'Select'c11', 'c5'ESC 'c11'= 'c5'Use Keyboard Again'c11'.' se ' 'c6'Your Command'c11': ' START_1:;se 'z0';gc;a=result;if index('H?/UMQAKCGDB',a)=0 & c2d(a)~=27 & c2d(a)~=13 then signal START_1 if c2d(a)=13 then signal START_3;if c2d(a)=27 then signal START_2 if index('H?/',a)~=0 then do;mf1=10;se c11'Help Mode';if help='ON' then help='OFF';else help='ON';signal START;end if help='ON' then do;call HELP(1''index('NPH?/UMQAKCGDB',a));signal START;end if a='U' then do;mf1=11;se c12'Use Another Menu';call USEMENU;signal START;end if a='M' then do;mf1=12;se c11'Maintenance Menu';mflag=1;signal MAINT;end if a='Q' then do;mf1=13;tr c12'Quit to Main>';changewhere oldwhere;call SAVEUSER;exit;end if a='A' then do;tr c11'Add Activity';signal ADDACT;end;if a='K' then do;tr c12'Kill Activity';signal KILLACT;end if a='C' then do;tr c11'Change Colorsf1@4';signal COLORS;end;if a='G' then do;tr c12'Graphics Changef1@4';signal NEWGRAP;end if a='D' then do;tr c11'Documentation File';call READDOCS;signal START;end;if a='B' then do;tr c12'Borrow Config';signal BORROW;end START_2:;do 2;mg;a=result;end;if a='NOCHAR' then do;tr c5'Keyboard Mode';ansi='OFF';call SAVEUSER;signal START;end if index('ABCD',a)=0 then signal START_1;if mf1<10 then do;c=c7;if mf1%2=mf1/2 then c=c8;end else do;c=c12;if mf1%2=mf1/2 then c=c11;end;if mf1<10 then zz=0;else zz=1;tr c'['mf1+5+zz';31Hz0 'it1.mf1'z0' if a='A' then do;do until mf1<1 | it1.mf1~='';mf1=mf1-1;end;if mf1<1 then mf1=13;end if a='B' then do;do until mf1>13 | it1.mf1~='';mf1=mf1+1;end;if mf1>13 & tot.menu=0 then mf1=10;if mf1>13 then mf1=1;end if a='C' then do;tr c11'Next Menu';menu=menu+1;if menu>menus then menu=0;mf1=1;if tot.menu=0 then mf1=10;signal START;end if a='D' then do;tr c12'Previous Menu';menu=menu-1;if menu<0 then menu=menus;mf1=1;if tot.menu=0 then mf1=10;signal START;end if mf1<10 then zz=0;else zz=1;tr '['mf1+5+zz';31Hz4cf*'it1.mf1'z0';signal START_1 START_3:;a=mf1;if a<10 then do;a=a+14;signal START3;end;if a=10 then a=3;if a=11 then a=6 if a=12 then a=7;if a=13 then a=8;signal START3 START2:;bufferflush;gc;z=result;call CHECK;a='';if c2d(z)=27 & useansi=1 then do;do 2;mg;a=result;end;if a~='NOCHAR' then signal START2;end if a='NOCHAR' then do;se c5'Ansi Menus';ansi='ON';call SAVEUSER;signal START;end if c2d(z)=13 then z='Q';a=index('NPH?/UMQAKCGDB'||m,z);call CHECK;if a=0 then signal START2 START3:;if a=3 | a=4 | a=5 then do;se c11'Help Mode';if help='ON' then help='OFF';else help='ON';signal START;end if help='ON' then do;call HELP(1''a);signal START;end if a=1 & menu0 then do;se c12'Previous Menu';menu=menu-1;signal START;end if a=6 then do;se c12'Use Another Menu';call USEMENU;signal START;end if a=7 then do;se c11'Maintenance Menu';mflag=1;signal MAINT;end if a=8 then do;tr c12'Quit to Main>';changewhere oldwhere;call SAVEUSER;exit;end if a=9 then do;tr c11'Add Activity';signal ADDACT;end if a=10 then do;tr c12'Kill Activity';signal KILLACT;end if a=11 then do;tr c11'Change Colorsf1@4';signal COLORS;end if a=12 then do;tr c12'Graphics Changef1@4';signal NEWGRAP;end if a=13 then do;tr c11'Documentation File';signal READDOCS;end if a=14 then do;tr c12'Borrow Config';signal BORROW;end if a>14 then do;a=a-14;item=act.menu.a;changewhere name.item;old=result if more.item=1 then call NOMORE;se c5||name.item'f1@'more.item*4''load.item'}' if pause.item=1 then se 'n1'pausebar;changewhere old;if more.item=1 then call MORE;signal START;end signal START2 MAINT:;tr 'f1@4'c5||sp||center(menu.menu' (Menu #'menu')',38) tr sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'c3||c4||center('Maintenance Menu',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0';mflag=1;if ansi='ON' then signal MAINT0 if help='ON' then tr sp||c5' Press 'c11'"'c9'H'c11'" 'c5'to turn 'c9'HELP 'c5'off.n1';else tr if borrow=1 then do se c7'The 'c9'Maintenance Menu 'c7'is 'c2'INACTIVE'c7', because you are using a ' tr c5'BORROWED 'c9'LogActs3 'c11'Config'c7'.n1' se 'In this instance, you have 'c5'three 'c7'choices. You can 'c6'['c5'E'c6']'c8'xit ' se c9'Maintenance Menu'c7', 'c6'['c5'R'c6']'c8'eload 'c13'YOUR 'c9'LogActs3 'c11'Config'c7', or ' tr c6'['c5'A'c6']'c8'dopt 'c7'this 'c9'LogActs3 'c11'Config'c7'.n1' se c13'Your choice? 'c6'('c7'E'c6'/'c8'r'c6'/'c11'a'c6')'c9': ';gc;a=result if a~='R' & a~='A' then do;tr c7'Exit';signal START;end if a='R' then do;tr c8'Reload';file=file1;call READUSER;borrow=0;signal START;end;else tr c11'Adopt' file=file1;call SAVEUSER;borrow=0;signal START;end tr sp||in||c5'*'c9'A'c10'> 'c11'Add Activity';tr sp||in||c5'*'c9'K'c10'> 'c12'Kill Activity' tr sp||in||c5' 'c9'N'c10'> 'c11'New Menu Name';tr sp||in||c5' 'c9'M'c10'> 'c12'Make a Menu' tr sp||in||c5' 'c9'R'c10'> 'c11'Remove a Menu';tr sp||in||c5'*'c9'C'c10'> 'c12'Change Colors' tr sp||in||c5'*'c9'G'c10'> 'c11'Graphic Change';tr sp||in||c5' 'c9'P'c10'> 'c12'Pause Bar Edit' tr sp||in||c5' 'c9'H'c10'> 'c11'Help Mode 'c5'['c9||help||c5'] ';tr sp||in||c5'*'c9'D'c10'> 'c12'Docs (DL or Read)' tr sp||in||c5'*'c9'B'c10'> 'c11'Borrow A Config';tr sp||in||c5' 'c9'U'c10'> 'c12'Use Another Menu' tr sp||in||c5' 'c9'Q'c10'> 'c11'Quit Maintenance';tr sp||in||c5' 'c9'X'c10'> 'c12'X-it to Main:n1' tr sp||c5'* 'c6'= 'c9'Works in 'c6'"'c5||menu.menu||c6'"'c9' Menu also'c6'!' se sp||c13'Maint? 'c6'('c9'A'c6'/'c9'K'c6'/'c9'N'c6'/'c9'M'c6'/'c9'R'c6'/'c9'C'c6'/'c9'G'c6 tr '/'c9'P'c6'/'c9'H'c6'/'c9'D'c6'/'c9'B'c6'/'c9'U'c6'/'c8'['c9'Q'c8']'c6'/'c9'X'c6')' if useansi=1 then se sp||c5'ESC 'c6'= 'c5'Ansi 'c9'Menus'c6'> ';else se sp||c6'Your Command'c9'> ';signal MAINT1 MAINT0:;do i=1 to 14;c=c11' ';if i%2=i/2 then c=c12' ';if i=mf2 then c='z4cf*' tr '['i+5';31H'c||it2.i'z0';if i=9 then tr ''c5'['c9||help||c5'] ';end i tr ''c7'Up'c11'/'c7'Down 'c11'= 'c7'Choose Item'c11', 'c8'Left'c11'/'c8'Right 'c11'= 'c8'Change Menu'c11',' tr ' 'c9'ENTER 'c11'= 'c9'Select'c11', 'c5'ESC 'c11'= 'c5'Use Keyboard Again'c11'.';se ' 'c6'Your Command'c11': ' MAINT_1:;se 'z0';gc;a=result;if index('AKNMRCGPH?/DBUQX',a)=0 & c2d(a)~=13 & c2d(a)~=27 then signal MAINT_1 if c2d(a)=13 then signal MAINT_3;if c2d(a)=27 then signal MAINT_2 if index('H?/',a)~=0 then do;mf2=9;tr c11'Help Mode';if help='ON' then help='OFF';else help='ON';signal MAINT;end if help='ON' then do;call HELP(2''index('AKNMRCGPH?/DBUQX',a));signal MAINT;end if a='A' then do;mf2=1;tr c11'Add Activity';signal ADDACT;end;if a='K' then do;mf2=2;tr c12'Kill Activity';signal KILLACT;end if a='N' then do;mf2=3;tr c11'New Menu Name';signal NEWNAME;end;if a='M' then do;mf2=4;tr c12'Make New Menu';signal MAKEMENU;end if a='R' then do;mf2=5;tr c11'Remove A Menu';signal REMOVEMENU;end;if a='C' then do;mf2=6;tr c12'Change Colorsf1@4';signal COLORS;end if a='G' then do;mf2=7;tr c11'Graphics Changef1@4';signal NEWGRAP;end;if a='P' then do;mf2=8;tr c12'Pause Bar Edit';signal NEWPAUSE;end if a='D' then do;mf2=10;tr c12'Documentation File';signal READDOCS;end;if a='B' then do;mf2=11;tr c11'Borrow Config';signal BORROW;end if a='U' then do;mf2=12;tr c12'Use Another Menu';call USEMENU;signal MAINT;end;if a='Q' then do;mf2=13;tr c11'Quit Maintenance';mflag=0;signal START;end if a='X' then do;mf2=14;tr c12'X-it to Main:';changewhere oldwhere;call SAVEUSER;exit;end MAINT_2:;do 2;mg;a=result;end;if a='NOCHAR' then do;tr c5'Keyboard Mode';ansi='OFF';call SAVEUSER;signal MAINT;end if index('ABCD',a)=0 then signal MAINT_1;c=c11;if mf2%2=mf2/2 then c=c12;tr c'['mf2+5';31Hz0 'it2.mf2'z0' if a='A' then do;mf2=mf2-1;if mf2<1 then mf2=14;end;if a='B' then do;mf2=mf2+1;if mf2>14 then mf2=1;end if a='C' then do;menu=menu+1;if menu>menus then menu=0;signal MAINT;end if a='D' then do;menu=menu-1;if menu<0 then menu=menus;signal MAINT;end tr '['mf2+5';31Hz4cf*'it2.mf2'z0';signal MAINT_1 MAINT_3:;a=mf2;if mf2>9 then a=mf2+2;signal MAINT2 MAINT1:;bufferflush;gc;z=result;call CHECK;a='';if c2d(z)=27 & useansi=1 then do;do 2;mg;a=result;end;if a~='NOCHAR' then signal MAINT1;end if a='NOCHAR'then do;se c5'Ansi Menus';ansi='ON';call SAVEUSER;signal MAINT;end if c2d(z)=13 then z='Q';a=index('AKNMRCGPH?/DBUQX',z);call CHECK;if a=0 then signal MAINT1 MAINT2:;if a=9 | a=10 | a=11 then do;tr c11'Help Mode';if help='ON' then help='OFF';else help='ON';signal MAINT;end if help='ON' then do;call HELP(2''a);signal MAINT;end if a=1 then do;tr c11'Add Activity';signal ADDACT;end if a=2 then do;tr c12'Kill Activity';signal KILLACT;end if a=3 then do;tr c11'New Menu Name';signal NEWNAME;end if a=4 then do;tr c12'Make New Menu';signal MAKEMENU;end if a=5 then do;tr c11'Remove A Menu';signal REMOVEMENU;end if a=6 then do;tr c12'Change Colorsf1@4';signal COLORS;end if a=7 then do;tr c11'Graphics Changef1@4';signal NEWGRAP;end if a=8 then do;tr c12'Pause Bar Edit';signal NEWPAUSE;end if a=12 then do;tr c12'Documentation File';signal READDOCS;end if a=13 then do;tr c11'Borrow Config';signal BORROW;end if a=14 then do;tr c12'Use Another Menu';call USEMENU;signal MAINT;end if a=15 then do;tr c11'Quit Maintenance';mflag=0;signal START;end if a=16 then do;tr c12'X-it to Main:';changewhere oldwhere;call SAVEUSER;exit;end ADDACT:;a=totacts;lo=1;hi=10;if a<10 then hi=a;if lw=80 & tot.menu<9 then signal ADDACT4 ADDACT1:;tr 'f1@4'c5||sp||center(menu.menu,38);tr sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'c3||c4||center('Add Activities Menu',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1';if tot.menu=9 then do se c9||menu.menu||c7' is 'c11'completely 'c7'filled. Try either ' se c9'adding 'c7'to another menu, or 'c13'killing 'c7'one or more ' tr c5'Activities 'c7'from this menu. 'pausebar;signal START;end a=0;b='ABCDEFGHIJ';do i=lo to hi;a=a+1;c=c7;if i//2=0 then c=c8 tr sp||in||c5||substr(b,a,1)||c6'> 'c||name.i;end i tr 'n1'sp||in||c9'N'c10'> 'c11'Next 10 Activities';tr sp||in||c9'P'c10'> 'c12'Past 10 Activities' if lw=80 then do;tr sp||in||c9'S'c10'> 'c11'Show ALL Activities';s=c9'S'c6'/';end;else s='' tr sp||in||c9'U'c10'> 'c11'Use Another Menu';tr sp||in||c9'Q'c10'> 'c12'Quit Addingn1' se sp||c13'Add Which? 'c6'('c5'A'c6'-'c5||substr(b,a,1)||c6'/'c9'N' se c6'/'c9'P'c6'/'s||c9'U'c6'/'c9'Q'c6')'c13': 'c9 ADDACT2:;gc;b=result;c=index('ABCDEFGHIJNPSUQ',b);if c=0 then c=15;if (c<11 & c>a) then signal ADDACT2 if c=11 & hitotacts then hi=totacts;signal ADDACT1;end if c=12 & lo>1 then do;tr 'Past 10';lo=lo-10;hi=lo+9;signal ADDACT1;end if c=13 & lw=80 then do;tr 'Show ALL';signal ADDACT4;end if c=14 then do;tr 'Use Another Menu';call USEMENU;signal ADDACT1;end if c=15 then do;tr 'Quit Adding';if mflag=0 then signal START;else signal MAINT;end if c>a then signal ADDACT2;d=lo+c-1;se c5||name.d;flag=1 ADDACT3:;tr 'f1@4n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'c3||c4||center(menu.menu,36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1';if group 'c||name.item end i;se 'n1'sp||c5'Add 'c6'"'c7||name.d||c6'" 'c5'to 'c9 se menu.menu||c5'? 'c6'('c7'Y'c6'/'c8'n'c6')'c5': ';gc;a=result if a='N' then do;tr c8'No.';if flag=1 then signal ADDACT;else signal ADDACT4;end se c7'Yes!n2'sp||c9'Adding...';tot.menu=tot.menu+1;a=tot.menu act.menu.a=d;men.menu=tot.menu'|'menu.menu;call SAVEUSER;tr c13'Done!' if tot.menu<9 & flag=1 then signal ADDACT1;if tot.menu<9 & flag=2 then signal ADDACT4;signal START ADDACT4:;tr 'f1'c3||c4'[ Show ALL Activities ]z0 'c9'Current Menu'c10': 'c11||menu.menu'n1' c=c7;do i=1 to totacts by 3;j=i+1;k=j+1;se c5||right(i,2)||c6'> 'c||left(name.i,20) if name.j>'' then se c5' 'right(j,2)||c6'> 'c||left(name.j,20);if name.k>'' then se c5' 'right(k,2)||c6'> 'c||left(name.k,20) tr;if c=c7 then c=c8;else c=c7;end i se c13'n1Add Which Activity? 'c10'('c5'1'c10'-'c5||totacts||c10'/'c9'U'c11'se' se c10'/'c9'Q'c11'uit'c10')'c13':'c5'i16513 2}';gu 70;a=result;if a='Q' then signal MAINT if a='U' then do;call USEMENU;signal ADDACT4;end;if (a<1 | a>totacts) & mflag=1 then signal MAINT if (a<1 | a>totacts) & mflag=0 then signal START;else d=a;signal ADDACT3 USEMENU:;tr 'f1@4n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'c3||c4||center('Use Another Menu',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1';do i=0 to menus;c=c7;if i//2=0 then c=c8 tr sp||in||c5||right(i,2)||c6'> ('c||tot.i||c6') 'c||menu.i;end i;a='' if lw=80 & mflag=0 then do;a=c6'/'c5'B';tr sp||in||c5' B'c6'> 'c13'Use 'c9'BIG 'c13'Menu';end se 'n1'sp||c13'Use Which? 'c6'('c5'0'c6'-'c5||menus||a||c6')'c13': 'c5'i0 2}';gu 70 a=upper(result);if a='B' & mflag=0 then signal BIGMENU;if a<0 | a>menus then a=menu;menu=a;return BIGMENU:;tr 'f1'c3||c4'[ The BIG Activity Menu ]z0 'c9||totacts||c11' Total Activitiesn1' c=c7;do i=1 to totacts by 3;j=i+1;k=j+1;se c5||right(i,2)||c6'> 'c||left(name.i,20) if name.j>'' then se c5' 'right(j,2)||c6'> 'c||left(name.j,20);if name.k>'' then se c5' 'right(k,2)||c6'> 'c||left(name.k,20) tr;if c=c7 then c=c8;else c=c7;end i se c13'n1Use Which Activity? 'c10'('c5'1'c10'-'c5||totacts||c10'/'c9'Q'c11 se 'uit'c10'/'c9'X'c11'-it'c10')'c13':'c5'i16513 2}';gu 70;a=result if a='X' then do;changewhere oldwhere;call SAVEUSER;exit;end;if a='Q' | a<1 | a>totacts then signal START item=a;changewhere name.item;old=result;if more.item=1 then call NOMORE;se 'f1@'more.item*4''load.item'}' if pause.item=1 then se 'n1'pausebar;changewhere old;if more.item=1 then call MORE;signal BIGMENU KILLACT:;tr 'f1@4n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'c3||c4||center(menu.menu,36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1';if tot.menu=0 then do tr sp||c5' No Activities to KILL in this Menu!';end do i=1 to tot.menu;c=c7;if i//2=0 then c=c8 item=act.menu.i;tr sp||in||c5||i||c6'> 'c||name.item;end i tr 'n1'sp||in||c9'U'c10'> 'c11'Use Another Menu' tr sp||in||c9'Q'c10'> 'c11'Quit Killingn1';a='';b=tot.menu if b>1 then a='1'c6'-'c5||tot.menu||c6'/';if b=1 then a='1'c6'/' se sp||c13'Kill Which? 'c6'('c5||a||c9'U'c6'/'c9'Q'c6')'c13': 'c5 KILLACT2:;gc;a=index('123456789UQ',result);if a=0 then a=11 if a<10 & a>tot.menu then signal KILLACT2 if a=11 then do;tr c9'Quit Killing';if mflag=1 then signal MAINT;else signal START;end if a=10 then do;tr c9'Use Another Menu';call USEMENU;signal KILLACT;end item=act.menu.a;se name.item'n2'sp||c13'Kill 'c5'"'c7||name.item||c5'" 'c13'from ' se c9'n1'sp||menu.menu||c13'? 'c6'('c5'Y'c6'/'c9'n'c6')'c13': ';gc;b=result if b='N' then do;tr c9'No.';signal KILLACT;end;se c5'Yes!n2'sp||c13'Killing...';act.menu.a='' do i=1 to tot.menu;j=i+1;if act.menu.i='' then do;act.menu.i=act.menu.j;act.menu.j='';end;end i tot.menu=tot.menu-1;men.menu=tot.menu'|'menu.menu call SAVEUSER;tr c11'Done!';if tot.menu>0 then signal KILLACT;signal START COLORS:;c1 ='z'||v.1;c2 ='c'||v.2;c3 ='z'||v.3;c4='c'||v.4 c5 ='c'||v.5;c6 ='c'||v.6;c7 ='c'||v.7;c8 ='c'||v.8 c9 ='c'||v.9;c10='c'||v.10;c11='c'||v.11;c12='c'||v.12 c13='c'||v.13;tr 'f0n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'c3||c4||center('Example Color Menu',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1' tr sp||in||c5'1'c6'> 'c7'Activity 1 (Odd)';tr sp||in||c5'2'c6'> 'c8'Activity 2 (Even)n1' tr sp||in||c9'A'c10'> 'c11'Command A (Odd)';tr sp||in||c9'B'c10'> 'c12'Command B (Even)n1' tr sp||in||c13'Prompt? 'c6'('c5'1'c6'-'c5'2'c6'/'c9'A'c6'/'c9'B'c6')'c13':n1' tr sp||c5'A'c6': 'c7'Frame BkGrnd 'c5'B'c6': 'c8'Frame FrGrnd' tr sp||c5'C'c6': 'c8'Title BkGrnd 'c5'D'c6': 'c7'Title FrGrnd' tr sp||c5'E'c6': 'c7"Menu Item #'s "c5'F'c6': 'c8"Menu Item >'s" tr sp||c5'G'c6': 'c8'Odd Menu Items 'c5'H'c6': 'c7'Even Menu Items' tr sp||c5'I'c6': 'c7"Command #'s "c5'J'c6': 'c8"Command >'s" tr sp||c5'K'c6': 'c8'Odd Commands 'c5'L'c6': 'c7'Even Commands' tr sp||c5'M'c6': 'c7'Prompt Color 'c5'N'c6': 'c8'Use NEW Colors' tr sp||c9'S'c10': 'c11'Save & Quit 'c9'Q'c10': 'c12'Quit NO Save!n1' se sp||c13'Option? 'c6'('c5'A'c6'-'c5'N'c6'/'c9'S'c6'/'c9'Q'c6')'c13': ' gc;a=index('ABCDEFGHIJKLMNSQ',result);if a=0 then a=16 if a=16 then do;tr c12'Quit NO Save';call READUSER;if mflag=1 then signal MAINT;else signal START;end if a=15 then do;tr c11'Save & Quit';call SAVEUSER;if mflag=1 then signal MAINT;else signal START;end if a=14 then do;tr c5'New Colors';signal NEWCOLORS;end;else tr c5||c.a if a=1 | a=3 then do;se sp' 'c13'New Value: 'c6'('c5'0'c6'-'c5'7'c6')'c13': 'c5 gc;b=result;c=index('01234567',b);if c=0 then do c=index('01234567',v.a);b=c;if b=8 then b=0;end se b;v.a=b;signal COLORS;end se sp||c13' Value: 'c6'('c5'0'c6'-'c5'9'c6'/'c9'A'c6'-'c9'F'c6')'c13': 'c5 gc;b=result;c=index('0123456789ABCDEF',b);if c=0 then do c=index('0123456789abcdef',v.a);b=c+1;if b=17 then b=1 b=substr('0123456789abcdef',b,1);end se upper(b);v.a=b;signal COLORS;end;signal COLORS NEWCOLORS:;se sp||c13'Reset ALL Colors to White? 'c6'('c5'y'c6'/'c9'N'c6')'c13': ';gc;a=result if a~='Y' then do;se c9'No.';signal COLORS;end se c5'Yes!';do i=1 to 13;v.i=7;end i;v.1=0;v.3=0;signal COLORS NEWGRAP:;g1=substr(g.gr1,1,1);g2=substr(g.gr1,2,1);g3=substr(g.gr1,3,1) g4=substr(g.gr1,4,1);g5=substr(g.gr1,5,1);g6=substr(g.gr1,6,1) g7=substr(g.gr1,7,1);g8=substr(g.gr1,8,1) tr 'f0n1'sp||c1||c2||g1||copies(g2,36)||g3'z0';m='ABCDEFGHIJKL' tr sp||c1||c2||g4'z0'||c3||c4||center('Graphics Menu',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1';do i=1 to 12 by 2 j=i+1;c=c7;if (i+1)//4=0 then c=c8 se sp' 'c5||substr(m,i,1)||c6'> 'c||g.i' 'c5 tr substr(m,j,1)||c6'> 'c||g.j;end i tr 'n1'sp' 'c9'S'c10'> 'c11'Save & Quit 'c9'Q'c10'> 'c12'Quit Now' se 'n1'sp||c13'Which Graphics? 'c6'('c5'A'c6'-'c5'L'c6'/'c9'S' se c6'/'c9'Q'c6')'c13': 'c5'' gc;a=result;b=index('ABCDEFGHIJKLSQ',a);if b=0 then b=14 if b<13 then do;tr a;gr1=b;signal NEWGRAP;end if b=14 then do;tr c9'Quit Now';call READUSER if mflag=1 then signal MAINT;else signal START;end if b=13 then do;tr c9'Save & Quit';call SAVEUSER if mflag=1 then signal MAINT;else signal START;end NEWNAME:;tr 'f1n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'||c3||c4||center('New Menu Name',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1' tr sp||c5' Current Name'c6':'c1||c2' 'left(menu.menu,20)'z0';addkeys (menu.menu) se sp||c5'Type 'c9'New 'c5'Name'c6':'c3||c4' 'copies(' ',20) se 'i16 20}z0';gu 70;new=result;se 'n1'sp||c5'Use 'c6 tr '"'c9||new||c6'" 'c5'instead of';se sp' 'c6'"'c9||menu.menu se c6'"'c5'? 'c6'('c7'Y'c6'/'c8'n'c6')'c5': ';gc;a=result if a='N' then do;tr c8'No.';signal MAINT;end tr c7'Yes!';men.menu=tot.menu'|'new;m=menu call SAVEUSER;call READUSER;menu=m;signal MAINT NEWPAUSE:;tr 'f1n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'||c3||c4||center('New Pause Bar',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1' tr sp||c5' Current Pause Bar'c6':'c1||c2' 'left(pause,30)'z0';addkeys (pause) se sp||c5'Type 'c9'New 'c5'Pause Bar'c6':'c3||c4' 'copies(' ',30) se 'i256 30}z0';gu 70;new=result;se 'n1'sp||c5'Use 'c6 tr '"'c9||new||c6'" 'c5'instead of';se sp' 'c6'"'c9||pause se c6'"'c5'? 'c6'('c7'Y'c6'/'c8'n'c6')'c5': ';gc;a=result if a='N' then do;se c8'No.';signal MAINT;end se c7'Yes!';pause=new;pausebar=pause||'i1' call SAVEUSER;call READUSER;signal MAINT BORROW:;tr 'f1@4n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'||c3||c4||center('Borrow A Config',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1'c7 se ' The 'c6'Maintenance Menu 'c7'will 'c13'NOT 'c7'work ' se 'when using a 'c11'Borrowed Config'c7'. You can only 'c9'View ' tr c7'and 'c9'Use 'c7'the 'c6'Menus 'c7'from that 'c11'Config'c7'.n1' se c13'Want to continue 'c6'['c9'Yes'c6']'c13'? 'c9;gc;a=result if a='N' then do;tr 'No.';if mflag=1 then signal MAINT;else signal START;end se 'Yes!n2'c13'Enter a 'c9'Handle'c13', 'c9'Real Name'c13', or 'c9'ID Number ' se c13'to 'c11'Borrow 'c13'from'c7':'c9'i144 20}';gu 70;a=result file1=file;findaccount a;st=result;if st=0 then do se c13'n1Invalid Account. 'pausebar;if mflag=1 then signal MAINT;else signal START;end loadscratch st;savescratch (-st);gs 39;a=result;gs 1;h=result file='mail:users/'||a||'/_LogActs3';if ~exists(file) then do se 'n1'c5||h' 'c7'does not have a 'c11'LogActs3 Config 'c7'yet. 'pausebar if mflag=1 then signal MAINT;else signal START;end se 'n1'c13'Use 'c7||h"'s "c11'Config'c6' ['c9'Yes'c6']'c13'? 'c9;gc;a=result if a='N' then do;tr 'No.';if mflag=1 then signal MAINT;else signal START;end se 'Yes!n2'c7'To revert back to 'c5'YOUR 'c9'LogActs3 Config'c7', simply select ' se c9'M'c10'>'c11'aintenance Menu 'c7"again. You'll be asked if you wish to " se c8'ADOPT 'c7'the 'c11'Borrowed Config'c7', or 'c8'reload 'c5'YOUR OWN ' tr c9'Config'c7' again.n2'sp||in||pausebar;se c13'Loading 'c7||h"'s "c9'LogActs3 Config'c13'...' call READUSER;borrow=1;signal START MAKEMENU:;tr 'f1@4n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'||c3||c4||center('Make A Menu',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1' se sp||c13'Make a 'c7'NEW 'c11'Menu 'c13'now? 'c6'('c5'y'c6'/' se c9'N'c6')'c13': ';gc;a=result;if a='Y' then tr c5'Yes!' if a~='Y' then do;tr c9'No.';signal MAINT;end MAKEMENU2:;se 'n1'sp||c5'Type 'c9'New 'c5'Name'c6':'c3||c4' 'copies(' ',20) se 'i16 20}z0';gu 70;new=result if new='' then new='Menu '||menus+1;se 'n1'sp||c5'Use 'c6 se '"'c9||new||c6'"'c5'? 'c6'('c7'Y'c6'/'c8'n'c6')'c5': ' gc;a=result;if a='N' then do;tr c8'No.';signal MAKEMENU2;end tr c7'Yes!';m=new;menus=menus+1;men.menus='0|'||m tot.menus=0;call SAVEUSER;call READUSER;menu=menus;signal START REMOVEMENU:;tr 'f1@4n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'||c3||c4||center('Remove A Menu',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1';if menus=0 then do tr sp||c5' No Menus to Remove!';end do i=1 to menus;c=c7;if i//2=0 then c=c8;tr sp||in||c5||i||c6'> 'c||menu.i end i;tr 'n1'sp||in||c9'Q'c10'> 'c11'Quit Removing.n1';a='' if menus>1 then a='1'c6'-'c5||menus||c6'/';if menus=1 then a='1'c6'/' se sp||c13'Remove which? 'c6'('c5||a||c9'Q'c6')'c13': 'c5'i0 2}';gu 70 a=result;if a<1 | a>menus then a='Q' if a='Q' then do;tr c9'Quit Removing';signal MAINT;end if tot.a>0 then do se 'n1'c7'There are 'c5'Activities 'c7'located in this 'c9'Menu'c7'. If you 'c13'Remove ' se c7'this 'c9'Menu'c7', then all 'c5'Activities 'c7'within this 'c9'Menu 'c7'will also ' se 'be 'c13'Removed'c7'. Are you 'c12'SURE'c7'? 'c6'('c5'y'c6'/'c9'N'c6')'c7': ';gc b=result;if b~='Y' then do;tr c9'No.';signal MAINT;end;else tr c5'Yes!';end men.a='';do i=1 to menus;j=i+1;if men.i='' then do men.i=men.j;men.j='';mact.i=mact.j;mact.j='';tot.i=tot.j do k=1 to words(mact.i);act.i.k=word(mact.i,k);end k;end;end i menus=menus-1;call SAVEUSER;call READUSER;signal REMOVEMENU READACTS:;if ~exists('pfiles:LogActs3/Activities') then do se 'c6There are c9NO ceActivities c6defined for use by cbLogon' se " Activitiesc6. You'll have to wait until your cfSysOp " tr 'c6has cdAdded c6some ceActivitiesc6...c7<c9enterc7>i1' changewhere oldwhere;call SAVEUSER;exit;end call open(f1,'pfiles:LogActs3/Activities','r') totacts=readln(f1);do i=1 to totacts;act.i=readln(f1) parse var act.i date.i'|'load.i'|'name.i'|'pause.i'|'group.i'|'more.i'|'j if date.i>date then do;ntot=ntot+1;nact.ntot=name.i;end;end i call close(f1);return SAVEUSER:;v='';do i=1 to 13;v=v||v.i||' ';end i;data=menus' 'v||gr1' 'ansi' 'menu call open(f1,file,'w');call writeln(f1,ver);call writeln(f1,data) call writeln(f1,pause);do i=0 to menus;call writeln(f1,men.i) a='';do j=1 to tot.i;a=a||act.i.j||' ';end j;call writeln(f1,a);end i call close(f1);return SETUP:;gu 39;file='mail:users/'||result||'/_LogActs3';ntot=0;gu 27;lw=result gu 1307358;last=upper(left(result,3));sp='';if lw=80 then sp=copies(' ',20) in=copies(' ',8);help='OFF';borrow=0;tr '@4';gu 28;tp=result mo='JanFebMarAprMayJunJulAugSepOctNovDec';gu 11;d=result;newuser=0 d1=index(mo,substr(d,8,3))%3+1;name.='';gu 15;group=result;mflag=0 t=time('n');time=left(t,2)||substr(t,4,2)||right(t,2) date=substr(d,12,4)||right(d1,2,'0')||right(strip(substr(d,5,2)),2,'0')||time if (tp=2 | tp=4) & lw=80 then useansi=1;else useansi=0 g.1 =".-.||`-'";g.2 ='o=o||o=o';g.3 ='ÚÄ¿³³ÀÄÙ';g.4 ='ÉÍ»ººÈͼ' g.5 ='Õ͸³³Ô;';g.6 ='ÖÄ·ººÓĽ';g.7 ='°°°°°°°°';g.8 ='±±±±±±±±' g.9 ='²²²²²²²²';g.10='ÛÛÛÛÛÛÛÛ';g.11='ÜÜÜÛÛßßß';g.12='ÛßÛÛÛÛÜÛ' c.1='Frame BkGrnd';c.2='Frame FrGrnd';c.3='Title BkGrnd' c.4='Title FrGrnd';c.5="Menu Item #'s";c.6="Menu Item >'s" c.7='Odd Menu Items';c.8='Even Menu Items';c.9="Command #'s" c.10="Command >'s";c.11='Odd Commands';c.12='Even Commands' c.13='Prompt Color';changewhere 'LogAct3 MENU';oldwhere=result mf1=1;mf2=1;it2.1='u1Au0dd Activity';it2.2='u1Ku0ill Activity' it2.3='u1Nu0ew Menu Name';it2.4='u1Mu0ake New Menu';it2.5='u1Ru0emove A Menu' it2.6='u1Cu0hange Colors';it2.7='Change u1Gu0raphics';it2.8='Edit u1Pu0ause Bar' it2.9='u1Hu0elp Mode';it2.10='u1Du0ocs (DL or Read)';it2.11='u1Bu0orrow A Config' it2.12='u1Uu0se Another Menu';it2.13='u1Qu0uit Maintenance';it2.14='Eu1xu0it to Main>' it1.10='u1Hu0elp Mode';it1.11='u1Uu0se Another Menu';it1.12='u1Mu0aintenance Menu' it1.13='u1Qu0uit to Main>';return READUSER:;if ~exists(file) then do if ~exists('pfiles:LogActs3/_Default') then do;se 'cfMaking LogActs Menus...' call open(f1,file,'w');call writeln(f1,pver);tt=1;if tp>1 then tt=3;t=totacts;a=t%5 if t//5>0 | t<5 then a=a+1 call writeln(f1,a' 0 7 0 7 7 7 7 7 7 7 7 7 7 'tt' OFF 1') call writeln(f1,'c6<c9enterc6>') call writeln(f1,'0|Auto Menu');call writeln(f1,'') do i=1 to a;b=5;if t<5 then b=t;else t=t-5 c='';do j=1 to b;c=c||(j+i*5)-5||' ';end j call writeln(f1,b||'|Menu '||i);call writeln(f1,c) end i;call close(f1);newuser=1;tr 'cdDonecf!';end else address command 'COPY pfiles:LogActs3/_Default 'file;end call open(f1,file,'r');ver=readln(f1) data=readln(f1);menus=word(data,1);do i=1 to 13;v.i=word(data,i+1) end i;gr1=word(data,15);ansi=word(data,16);last=word(data,17) pause=readln(f1);pausebar=pause||'i1' do i=0 to menus;men.i=readln(f1);parse var men.i tot.i'|'menu.i mact.i=readln(f1);do j=1 to tot.i;act.i.j=word(mact.i,j) end j;end i;call close(f1);menu=last;if menus=0 then menu=0 g1=substr(g.gr1,1,1);g2=substr(g.gr1,2,1);g3=substr(g.gr1,3,1) g4=substr(g.gr1,4,1);g5=substr(g.gr1,5,1);g6=substr(g.gr1,6,1) g7=substr(g.gr1,7,1);g8=substr(g.gr1,8,1);c1 ='z'||v.1 c2 ='c'||v.2;c3 ='z'||v.3;c4 ='c'||v.4;c5 ='c'||v.5 c6 ='c'||v.6;c7 ='c'||v.7;c8 ='c'||v.8;c9 ='c'||v.9 c10='c'||v.10;c11='c'||v.11;c12='c'||v.12;c13='c'||v.13 if newuser=1 then call WANTDOCS;if ntot>0 & newuser=0 then call NEWACTS;return HELP:;arg men2''com;tr 'f1@4n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' se sp||c1||c2||g4'z0'c3||c4||center('Logon Activities Help Screen',36) tr 'z0'c1||c2||g5'z0';tr sp||c1||c2||g6||copies(g7,36)||g8'z0' if men2=1 & com>14 then do;men2=0;com=com-14;item=act.menu.com;com=item;end if men2=1 & com>8 then do;men2=2;com=com-8;com=index('AK CG DB',substr('AKCGDB',com,1));end if men2=0 & ~exists('pfiles:LogActs3/ActsHelp/help.0.'item) then com=0;m.0='ActsHelp';m.1='MainMenu';m.2='MaintMenu' se '*4pfiles:LogActs3/'m.men2'/help.'men2'.'com'}n1'sp||in||pausebar;return WANTDOCS:;tr sp'f1n2'sp'z4'copies(' ',38)'z0n1'sp'z4cf Welcome to ceLogon Activitiescf, v'word(pver,2)' z0' tr sp'z4'copies(' ',38)'z0n1'sp'z4 cbBefore starting this program for z0' tr sp"z4 the first time, perhaps you'd like z0n1"sp'z4 to ceDOWNLOAD cba c9SHORT caText File cbthat z0' tr sp'z4 will cfHELP cbyou use ceLogActs3cb... z0n1'sp'z4'copies(' ',38)'z0n1' WANTDOCS2:;se sp' cdDOWNLOAD c6Text File Nowc6? c7[caYesc7]c6: ca';gc;a=result if a~='N' then do;se 'Yes!n2'sp'c6 The caLHA c6or c9ZIP cdVersionc6? c7[caLHAc7]c6: ca';gc;a=result if a='Z' then do;tr 'cfZIP';selectfile 'pfiles:LogActs3/LogActs3.ZIP';end else do;tr 'LHA';selectfile 'pfiles:LogActs3/LogActs3.LHA';end se 'n1 c6The file has been c9added c6to your cdDownload Select Bufferc6. You ' se 'can use the cb"caDScb" c6command to cdDownload c6the file at your cfleisurec6. 'pausebar;end else do;se 'No.n2c6 In that case, would you like to caREAD c6the cfText File c6now c7[caYesc7]c6: ca' gc;a=result;if a='N' then do;tr 'No.';return;end;else tr 'Yes!' tr 'f1q1*0pfiles:LogActs3/LogActs3.Doc}@4n1'pausebar;end;return READDOCS:;tr 'f1n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'||c3||c4||center('Logon Activities Docs',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1'c7;call WANTDOCS2;signal MAINT NEWACTS:;tr 'f1@4n1'sp||c1||c2||g1||copies(g2,36)||g3'z0' tr sp||c1||c2||g4'z0'||c3||c4||center('New Activities Added',36)'z0'c1||c2||g5'z0' tr sp||c1||c2||g6||copies(g7,36)||g8'z0n1'c7 se ' The following 'c5'Activities 'c7'have been 'c6'ADDED 'c7'to 'c13'Logon Activities 'c7 se 'since your last call. Use the 'c10'"'c9'A'c10'" 'c7'command in the 'c11'Maintenance ' tr 'Menu 'c7'to 'c6'ADD 'c7'these 'c5'Activities 'c7'to one or more of your 'c12'Menus'c7':n1' do i=1 to ntot;c=c7;if i//2=0 then c=c8;tr sp||in||c||nact.i;end i;se 'n1'sp||in||pausebar;return MORE:;setobject oldmore;putuser 1100454;return NOMORE:;getuser 1100454;oldmore=result;setobject 0;putuser 1100454;return CHECK:;getcarrier;zz=result;if zz='TRUE' then return;else tr 'f1n9c9Loss of Carrier!' logentry "Lost Carrier in LogActs, v"word(pver,2);changewhere oldwhere;call SAVEUSER;bufferflush;exit SYNTAX:;ERROR:;IOERR:;er=rc' c7<ce'errortext(rc)'c7> c6in line ca'sigl gu 1311992;a=result;gu 1311960;b=result;c='cb"cd'a||b'cb"';er='c9Error c6Code ca'er' c6of 'c'n2cf' er=er||sigl'ce: cb'sourceline(sigl);tr 'n1'er;logentry er;bufferflush /** Last Edited: 2-Jul-94 *************************************************\ \****************************************** FRONTIERS BBS (716)/823-9892 **/