home *** CD-ROM | disk | FTP | other *** search
/ Taifun Collection / Taifun_Collection_Vol_1.iso / richter / 8659 / 8659.mhs / RICHTER.DTP / KFZ / KFZ6.SC < prev    next >
Text File  |  1991-12-22  |  2KB  |  104 lines

  1. ; Kfz6
  2.  
  3.  
  4.  
  5. AppLib = "Kfz2"
  6. if (not isfile(AppLib + ".lib")) then
  7.   Createlib AppLib
  8. endif
  9.  
  10.  
  11. proc Kfz6S1()
  12. private opResult
  13.  
  14.   Readlib "Kfzutl"  ReportTable
  15.  
  16.   opResult = ReportTable("Lager1", "Lager1", "1", "Printer", "")
  17.  
  18.   Release Procs ReportTable
  19.  
  20.   return opResult
  21. endproc
  22.  
  23. Writelib AppLib Kfz6S1
  24. Release Procs Kfz6S1
  25.  
  26. proc Kfz6S3()
  27. private opResult
  28.  
  29.   Readlib "Kfzutl"  ReportTable
  30.  
  31.   opResult = ReportTable("Auftrag", "Auftrag", "3", "Printer", "")
  32.  
  33.   Release Procs ReportTable
  34.  
  35.   return opResult
  36. endproc
  37.  
  38. Writelib AppLib Kfz6S3
  39. Release Procs Kfz6S3
  40.  
  41. proc Kfz6Menu()
  42. private x, escape
  43.  
  44.   x = "Lagerbestand"
  45.   while (TRUE)
  46.     Clear
  47.  
  48.     ShowMenu
  49.         "Lagerbestand": "Lagerbestand drucken",
  50.         "Bestelliste": "Bestelliste drucken",
  51.         "Adressen": "Kundenadressen drucken",
  52.         "Auftrag": "Rechnungen und Kostenvoranschläge drucken",
  53.         "Leistungen": "Dienstleistungskatalog drucken, Leistungstab. für Aufträge"
  54.       Default x
  55.       To x
  56.  
  57.     switch
  58.       case x = "Lagerbestand":
  59.         ReadLib "Kfz2" Kfz6S1
  60.         escape = Kfz6S1()
  61.         escape = not escape
  62.         Release Procs Kfz6S1
  63.  
  64.       case x = "Bestelliste":
  65.         Play "Besteld"
  66.         x = "Bestelliste"
  67.         escape = FALSE
  68.  
  69.       case x = "Adressen":
  70.         ReadLib "Kfz2" Kfz6S3
  71.         escape = Kfz6S3()
  72.         escape = not escape
  73.         Release Procs Kfz6S3
  74.  
  75.       case x = "Auftrag":
  76.         ReadLib "Kfz3" Kfz9Menu
  77.         escape = Kfz9Menu()
  78.         escape = not escape
  79.         Release Procs Kfz9Menu
  80.  
  81.       case x = "Leistungen":
  82.         ReadLib "Kfz4" Kfz12Menu
  83.         escape = Kfz12Menu()
  84.         escape = not escape
  85.         Release Procs Kfz12Menu
  86.  
  87.       case x = "Esc":
  88.         return FALSE
  89.     endswitch
  90.  
  91.     ; Wert von ErrorProc zurücksetzen 
  92.     ErrorProc = "ApplicErrorProc"
  93.     ApplicErrorRetVal = FALSE
  94.  
  95.     if (not escape) then
  96.       return TRUE
  97.     endif
  98.   endwhile
  99. endproc
  100.  
  101. Writelib AppLib Kfz6Menu
  102. Release Procs Kfz6Menu
  103.  
  104.