home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / PASCAL / MAILER.ZIP / MAILER.SCR < prev    next >
Encoding:
Text File  |  1989-02-28  |  7.9 KB  |  203 lines

  1.  
  2. { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  3. |   Turbo Data Entry Screen Generated by ScreenGen (C) Copyright 1988   |
  4. |   Tika Software Co.      All Rights Reserved      LFB                 |
  5. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - }
  6.  
  7.  
  8. {------------------------------------------------------------------------
  9. |                           mailer_screen                               |
  10. ------------------------------------------------------------------------}
  11.  
  12. procedure mailer_screen( display_status : short_string );
  13.  
  14.  
  15. var XZZ18W : byte;
  16. var XZZ18W_start : long_string;
  17. begin
  18.  
  19.      with mailer_data do begin
  20. video( reverse );
  21.  
  22. { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  23. |   Output Screen (Writexy() statements.)                               |
  24. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - }
  25.  
  26. if pos('\1', display_status) <> 0 then begin
  27. writexy(1, 1, no_color, 'MAILER   Copyright (C) November, 1987 Alared            Records on File       ');
  28. writexy(1, 2, no_color, '');
  29. writexy(1, 3, no_color, 'Company       :                                                 ');
  30. writexy(1, 5, no_color, 'Contact       :                                                 ');
  31. writexy(1, 6, no_color, 'Street 1      :                               ');
  32. writexy(1, 7, no_color, 'Street 2      :                               ');
  33. writexy(1, 8, no_color, 'City          :                          ');
  34. writexy(1, 9, no_color, 'State         :   ');
  35. writexy(1, 10, no_color, 'Zip           :           ');
  36. writexy(1, 11, no_color, '');
  37. writexy(1, 12, no_color, 'Title         :                                  Phone :    -   -    -Ext:    ');
  38. writexy(1, 14, no_color, 'Contact Type  :            ');
  39. writexy(1, 16, no_color, 'Additional    :                                                               ');
  40. writexy(1, 17, no_color, 'Notes         :                                                               ');
  41. writexy(1, 18, no_color, '&             :                                                               ');
  42. writexy(1, 19, no_color, 'Information   :                                                               ');
  43. writexy(1, 22, no_color, '──────────────────────────────────────────────────────────────────────────────');
  44. end; {if}
  45.  
  46. { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  47. |   Echo the variable values to the screen.                             |
  48. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - }
  49.  
  50. if pos('\2', display_status) <> 0 then begin
  51. writexy(74,1, reverse, format(itoa( usedrecs( mailer_file )),'@@@@@', junkbyte));
  52. writexy(17,3, bright, format(company,
  53. '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@', junkbyte));
  54. writexy(17,5, bright, format(contact,
  55. '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@', junkbyte));
  56. writexy(17,6, dim, format(street1,'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@', junkbyte));
  57. writexy(17,7, no_color, format(street2,'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@', junkbyte));
  58. writexy(17,8, no_color, format(city,'@@@@@@@@@@@@@@@@@@@@@@@@@', junkbyte));
  59. writexy(17,9, no_color, format(state,'@@', junkbyte));
  60. writexy(17,10, no_color, format(zip,'@@@@@@@@@@', junkbyte));
  61. writexy(17,12, no_color, format(title,'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@', junkbyte));
  62. writexy(58,12, no_color, format(phone,'@@@-@@@-@@@@-Ext:@@@@', junkbyte));
  63.    contact_type := get_menu( 
  64.   '\1Vendor\2Client\3Prospect\4Other',
  65.   '',
  66.   contact_type,'\px17\py14\d');
  67. writexy(17,16, no_color, format(notes1,
  68. '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@', junkbyte));
  69. writexy(17,17, no_color, format(notes2,
  70. '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@', junkbyte));
  71. writexy(17,18, no_color, format(notes3,
  72. '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@', junkbyte));
  73. writexy(17,19, no_color, format(notes4,
  74. '@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@', junkbyte));
  75. end {if};
  76.  
  77. { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  78. |   Accept Variable Input.                                              |
  79. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - }
  80.  
  81.   if pos('\index', display_status) <> 0 then
  82.          XZZ18W:= search_index +17
  83.   else
  84.   if get_option( display_status, '\start', XZZ18W_start) then
  85.             XZZ18W := atoi(XZZ18W_start)
  86.   else XZZ18W := 1;
  87.  
  88.      if pos('\3',display_status) <> 0 then
  89.      repeat
  90.      if pos('\index', display_status) <> 0 then begin
  91.               message('SEARCH:Cursor Keysto Change Indices,<RETURN>to accept',1);
  92.               search_index := XZZ18W-17;
  93.      end; {if}
  94.  
  95.      case XZZ18W of
  96.  
  97. 2,19:  begin
  98.                company := get_string( company,'\x17\y3\l48\g\voB');
  99.  
  100.         if pos('\index', display_status) <> 0 then
  101.                 XZZ18W:= vieworder('',XZZ18W)
  102.         else               XZZ18W := vieworder( '\dc3', XZZ18W);
  103. end; {case 2}
  104.  
  105. 3,20:  begin
  106. message('CONTACT:Last, First  <--->  Example : Jones, Mr. Jim J.',1);
  107.                contact := get_string( contact,'\x17\y5\l48\g\voB');
  108.  
  109.         if pos('\index', display_status) <> 0 then
  110.                 XZZ18W:= vieworder('',XZZ18W)
  111.         else               XZZ18W := vieworder( '\dc4\uc2', XZZ18W);
  112. end; {case 3}
  113.  
  114. 4:  begin
  115.                street1 := get_string( street1,'\x17\y6\l30\voD');
  116.                XZZ18W := vieworder( '\dc5\uc3', XZZ18W);
  117. end; {case 4}
  118.  
  119. 5:  begin
  120.                street2 := get_string( street2,'\x17\y7\l30');
  121.                XZZ18W := vieworder( '\dc6\uc4', XZZ18W);
  122. end; {case 5}
  123.  
  124. 6:  begin
  125.                city := get_string( city,'\x17\y8\l25');
  126.                XZZ18W := vieworder( '\dc7\uc5', XZZ18W);
  127. end; {case 6}
  128.  
  129. 7:  begin
  130.                state := get_string( state,'\x17\y9\l2\u');
  131.                XZZ18W := vieworder( '\dc8\uc6', XZZ18W);
  132. end; {case 7}
  133.  
  134. 8:  begin
  135.                zip := get_string( zip,'\x17\y10\l10');
  136.                XZZ18W := vieworder( '\dc9\uc7', XZZ18W);
  137. end; {case 8}
  138.  
  139. 9:  begin
  140.                title := get_string( title,'\x17\y12\l30');
  141.                XZZ18W := vieworder( '\dc11\uc8', XZZ18W);
  142. end; {case 9}
  143.  
  144. 10:  begin
  145.                phone := get_string( phone,'\x58\y12\f@@@-@@@-@@@@-Ext:@@@@');
  146.                XZZ18W := vieworder( '\uc8', XZZ18W);
  147. end; {case 10}
  148.  
  149. 11:  begin
  150.                contact_type := get_menu( 
  151.   '\1Vendor\2Client\3Prospect\4Other',
  152.   '',
  153.   contact_type,'\px17\py14');
  154.                XZZ18W := vieworder( '\dc12\uc9', XZZ18W);
  155. end; {case 11}
  156.  
  157. 12:  begin
  158.                notes1 := get_string( notes1,'\x17\y16\l62');
  159.                XZZ18W := vieworder( '\dc13\uc11', XZZ18W);
  160. end; {case 12}
  161.  
  162. 13:  begin
  163.                notes2 := get_string( notes2,'\x17\y17\l62');
  164.                XZZ18W := vieworder( '\dc14\uc12', XZZ18W);
  165. end; {case 13}
  166.  
  167. 14:  begin
  168.                notes3 := get_string( notes3,'\x17\y18\l62');
  169.                XZZ18W := vieworder( '\dc15\uc13', XZZ18W);
  170. end; {case 14}
  171.  
  172. 15:  begin
  173.                notes4 := get_string( notes4,'\x17\y19\l62');
  174. if in_keycode <> k_up_cursor then exit;
  175.                XZZ18W := vieworder( '\uc14', XZZ18W);
  176. end {case 15}
  177.  
  178.      else XZZ18W := vieworder( '', XZZ18W );
  179.      end; {case}
  180.  
  181. { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  182. |   Adjust the variable index.                                          |
  183. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - }
  184.  
  185.      case XZZ18W of
  186. 0..16: 
  187.      if XZZ18W > 15 then
  188.                XZZ18W := 1
  189.      else if XZZ18W < 1 then
  190.                        XZZ18W := 15;
  191. 17..33: begin
  192.      if in_keycode = k_cr then exit;
  193.      if XZZ18W > 32 then
  194.                XZZ18W := 18
  195.      else if XZZ18W < 18 then
  196.                        XZZ18W := 32;
  197. end;
  198. end; {case}
  199.  
  200.      until in_keycode = k_escape; {perpetual loop}
  201.      end; {with}
  202. end; {procedure}
  203.