home *** CD-ROM | disk | FTP | other *** search
/ Chip: 25 Years Anniversary / CHIP_25Jahre_Jubilaeum.iso / downloads / 400616 / data1.cab / _lohnauskunft-Formulare / splitt.lsf < prev    next >
Text File  |  2003-04-01  |  3KB  |  133 lines

  1. Include "DruckNT.int"
  2. Include "Lak_NT.int"
  3.  
  4. 'Descriptions
  5. Description Form_Description as "Splittingtabelle"
  6. Description Form_Code as "Splittingtabelle"
  7. Description Page_Orientation as PAGE_PORTRAIT
  8.  
  9. SetBodyMargin(145,130,100,270)
  10. SetFooterMargin(155,250,155,100)
  11. Dim hNormal as FontType = CreateFont("Arial", 10, FONT_NORMAL, COLOR_BLACK)
  12. Dim hBold as FontType = CreateFont("Arial", 10, FONT_BOLD, COLOR_BLACK)
  13. Dim hMini as FontType = CreateFont("Arial", 8, FONT_NORMAL, COLOR_BLACK)
  14. Dim hTitel as FontType=CreateFont("Arial", 16, FONT_BOLD, COLOR_BLACK)
  15.  
  16. Dim i as Numeric
  17. Dim NumTmp as Numeric
  18.  
  19. Dim Datensatz as Bool
  20. Dim ESt as String
  21. Dim SolZ as String
  22. Dim GesBelastg as String
  23. Dim BelastgLetzte1000 as String
  24. Dim Waehrung as String
  25. Dim DiffWaehrg as Numeric
  26. Dim NumJahr as Numeric 
  27.  
  28.  
  29. NumJahr = GetInt("T",21)
  30.  
  31.  
  32. If  ( NumJahr <= 2001 )  Then
  33.  
  34.     Waehrung = "DM"
  35.     DiffWaehrg = 1000
  36.  
  37. Else
  38.  
  39.     Waehrung = "EUR"
  40.     DiffWaehrg = 500
  41.  
  42. End If
  43.  
  44.  
  45. Function Vordruck()
  46.     
  47.     RemoveAllTabs()
  48.     SetTabs("C910")
  49.     SelectFont(hTitel)
  50.     LF
  51.     TL( "\tSplittingtabelle " + FormatNumeric( "%0.0f", NumJahr ) )
  52.     RemoveAllTabs()
  53.     SelectFont(hNormal)
  54.     LF
  55.     NumTmp=GetPosY()
  56.     DrawLineExt(0,NumTmp,1820,NumTmp)
  57.     
  58.     DrawLineExt(0,0,1820,0)
  59.     DrawLineExt(0,2570,1820,2570)
  60.     DrawLineExt(0,0,0,2570)
  61.     DrawLineExt(550,NumTmp,550,2570)
  62.     DrawLineExt(720,NumTmp,720,2570)
  63.     DrawLineExt(1060,NumTmp,1060,2570)
  64.     DrawLineExt(1310,NumTmp,1310,2570)
  65.     DrawLineExt(1520,NumTmp,1520,2570)
  66.     DrawLineExt(1820,0,1820,2570)
  67.  
  68.     SetTabs("C275 C635 C890 C1185 C1415 C1670")
  69.     LF
  70.     TL("\tzu versteuerndes"+"\tZusatz-"+"\tTarifliche"+"\tSolidaritΣts-"+"\tGesamte"+"\tBelastung der")
  71.     TL("\tEinkommen"+"\tTabelle?"+"\tEinkommensteuer"+"\tzuschlag"+"\tBelastung"+"\tletzten"+FormatNumeric( "% 0.0f ", DiffWaehrg )
  72.         + Waehrung )
  73.     TL("\tin "+Waehrung+"\t"+"\tin "+Waehrung+"\tin "+Waehrung+"\tin %"+"\tin %")
  74.     LF
  75.     NumTmp=GetPosY()
  76.     DrawLineExt(0,NumTmp,1820,NumTmp)
  77.     LF
  78.     RemoveAllTabs()
  79.     SetTabs("R285 R505 C635 R985 R1270 R1460 R1720")
  80.     SelectFont(hNormal)
  81.     i=1
  82. End Function      
  83.  
  84.  
  85. Function GetWerte()
  86.     
  87.     ESt=StrAmt("T",2)
  88.     If ESt="0,00" then ESt="-" End If
  89.  
  90.     SolZ=StrAmt("T",16)
  91.     If SolZ="0,00" then SolZ="-" End If
  92.  
  93.     GesBelastg=StrAmt("T",4)
  94.     If GesBelastg="0,00" then GesBelastg="-" End If
  95.  
  96.     BelastgLetzte1000=StrAmt("T",5)
  97.     If BelastgLetzte1000="0,00" then BelastgLetzte1000="-" End If
  98.  
  99. End Function
  100.  
  101.  
  102. Function PrintFooter()
  103.     SelectFont(hMini)
  104.     RemoveAllTabs()
  105.     SetTabs("C910 R")
  106.     T("Lexware lohnauskunft "+GetProgramVersion()+"\t- " +PAGENUMBER+ " -\t"+FormatDate("%d.%m.%Y",Now()))
  107. End Function
  108.  
  109.  
  110. SetEventHandler(EVENT_START_PAGE,Vordruck)
  111. SetEventHandler(EVENT_PRINT_FOOTER,PrintFooter)
  112.  
  113. Vordruck()
  114. RemoveAllTabs()
  115. SetTabs("R295 R515 C635 R985 R1270 R1460 R1720")
  116. SelectFont(hNormal)
  117. Datensatz=FirstRecord("T")
  118.  
  119. Dim Zeilenhoehe as Numeric
  120.  
  121. Zeilenhoehe=GetLineHeight()
  122.  
  123. While Datensatz Do
  124.     GetWerte()
  125.     TL("\t"+StrAmt("T",6)+" bis"+"\t"+StrAmt("T",1)+"\t"+StrBool("T",3)+"\t"+ESt+"\t"+SolZ+"\t"+GesBelastg+"\t"+BelastgLetzte1000)
  126.     If i=5 AND (Zeilenhoehe<=2570-GetPosY()) Then
  127.         LF
  128.         i=0
  129.     End If
  130.     i=i+1
  131.     Datensatz=NextRecord("T")
  132. End While
  133.