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

  1.  
  2. Include "DruckNT.int"
  3. Include "Lak_NT.int"
  4.  
  5. 'Descriptions
  6. Description Form_Description as "Lohnabrechnung"
  7. Description Form_Code as "Arbeitnehmer Berechnung"
  8. Description Page_Orientation as PAGE_PORTRAIT
  9.  
  10.  
  11. Dim nAbrechJahr as Numeric = GetInt("D",2)
  12. Dim StrKurs as String
  13. Dim nBreite_cZahlgKorrWaehr as Numeric
  14. Dim nBreite_cZahlgWie as Numeric
  15.  
  16. If  ( nAbrechJahr < 2003 )  Then
  17.  
  18.   StrKurs = "Kurs: 1 EUR = 1,95583 DM"
  19.     nBreite_cZahlgKorrWaehr = 330
  20.     nBreite_cZahlgWie = 1190 
  21. Else
  22.     StrKurs = ""
  23.     nBreite_cZahlgKorrWaehr = 0
  24.     nBreite_cZahlgWie = 1520 
  25. End If 
  26.  
  27. 'Funktion, um die Kopfzeile zu schreiben
  28. Function OnPrintHeader()
  29.  
  30.             SetFont("Arial",12,FONT_BOLD,COLOR_BLACK)
  31.             SetTabs("L10 R1840")
  32.             T("\tAbrechnung der Brutto-Netto-Bezⁿge")
  33.             SetFont("Arial",12,FONT_NORMAL,COLOR_BLACK)
  34.             T("\t"+ StrStr("D",1) + " " + FormatNumeric("%0.0f", nAbrechJahr ) )            
  35.             LF
  36.             SetFont("Arial",10,FONT_NORMAL,COLOR_BLACK)
  37.             RemoveAllTabs()
  38.             SetTabs("")
  39.             'TL("\t" + StrStr("F",1) + " , " + StrStr("F",2) + " , " + StrStr("F",3) + " " + StrStr("F",4) 
  40.             '     )
  41.             'DrawHorzLine(FALSE)
  42.  
  43. End Function
  44.  
  45. function OnPrintFaltmarken()
  46. SetFooterMargin(30,2870,140,2600)
  47. DrawLineExt(0,750,90,750)
  48. DrawLineExt(0,1800,90,1800)
  49. end function
  50.  
  51. SetEventHandler(EVENT_PRINT_FOOTER, OnPrintFaltmarken)
  52.  
  53.  
  54.  
  55. 'Hauptteil
  56. SetHeaderMargin(150,80,100,100)
  57. SetBodyMargin(145,150,100,100)
  58. SetFooterMargin(160,190,105,100)
  59.  
  60. SetEventHandler(EVENT_PRINT_HEADER,OnPrintHeader)
  61.  
  62. Function BorderWidth(id as CellType, left as Numeric, top as Numeric, right as Numeric, bottom as Numeric)
  63.     SetCellBorder(id, CELL_BORDER_LEFT,left ,PEN_SOLID, COLOR_BLACK)
  64.     SetCellBorder(id, CELL_BORDER_TOP, top,PEN_SOLID, COLOR_BLACK)
  65.     SetCellBorder(id, CELL_BORDER_RIGHT, right,PEN_SOLID, COLOR_BLACK)
  66.     SetCellBorder(id, CELL_BORDER_BOTTOM,bottom ,PEN_SOLID, COLOR_BLACK)
  67. End Function
  68.  
  69. Function Cell( id as CellType, index as Numeric) as CellType
  70.     Cell=GetCellByIndex(id, index)
  71. End Function
  72.  
  73.  
  74. Function MinusAbsetzen(Zahl as Numeric) as String
  75.  
  76.     Dim StrHlp as String=""
  77.     Dim NumHlp as Numeric=Zahl
  78.     
  79.     If NumHlp<0 Then
  80.  
  81.         StrHlp=FormatAmt(-NumHlp)
  82.  
  83.         If "-"+StrHlp=FormatAmt(NumHlp) Then
  84.             MinusAbsetzen="- "+StrHlp
  85.         Else
  86.             MinusAbsetzen=FormatAmt(NumHlp)
  87.         End If
  88.     
  89.     Else
  90.         MinusAbsetzen=FormatAmt(NumHlp)
  91.     End If
  92.  
  93. End Function
  94.  
  95.  
  96. 'n zΣhlt Menge von EintrΣgen im Brutto-Feld, um Schriftart bei zu vielen zu verkleinern
  97. Dim n as Numeric
  98. If is("D",20) then n=n+1 End If
  99. If is("D",21) then n=n+1 End If
  100. If is("D",23) then n=n+1 End If
  101. If is("D",24) then n=n+1 End If
  102. If is("D",25) then n=n+1 End If
  103. If is("D",26) then n=n+1 End If
  104. If is("D",51) then n=n+1 End If
  105. If is("D",61) then else n=n+1 End If
  106. If is("D",72) then n=n+1 End If
  107. If is("D",73) then n=n+1 End If
  108. If is("D",74) then n=n+1 End If
  109. If is("D",75) then n=n+1 End If
  110. If is("D",76) then n=n+1 End If
  111. If is("E",1) then n=n+1 End If
  112.  
  113. 'm zΣhlt Menge von EintrΣgen im Netto-Feld, um Schriftart bei zu vielen zu verkleinern
  114. Dim m as Numeric
  115. If is("D",7) then else m=m+1 End If
  116. If is("D",10) then else m=m+1 End If
  117. If is("D",18) then m=m+1 End If
  118. If is("D",20) then m=m+1 End If
  119. If is("D",21) then m=m+1 End If
  120. If is("D",23) then m=m+1 End If
  121. If is("D",24) then m=m+1 End If
  122. If is("D",25) then m=m+1 End If
  123. If is("D",26) then m=m+1 End If
  124. If is("D",27) then m=m+1 End If
  125. If is("D",28) then m=m+1 End If
  126. If is("D",29) then m=m+1 End If
  127. If is("D",30) then m=m+1 End If
  128. If is("D",31) then m=m+1 End If
  129. If is("D",32) then m=m+1 End If
  130. If is("D",50) then m=m+1 End If
  131. If is("D",52) then m=m+1 End If
  132. If is("D",77) then m=m+1 End If
  133.  
  134. 'Schriftgr÷▀en festlegen
  135. Dim hBold as FontType        'Schrift fⁿr dickgedruckte Summenwerte
  136. Dim ExtraBold as FontType    'Schrift fⁿr Werte endgⁿltiger Auszahlung
  137. Dim hNormalB as FontType    'Schrift fⁿr Brutto-Aufschlⁿsselung
  138. Dim hNormalB2 as FontType    'Schrift fⁿr Bruttogehalts-Aufschlⁿsselung
  139. Dim hNormalN as FontType    'Schrift fⁿr Netto-Aufschlⁿsselung
  140. Dim hNormal2 as FontType    'Schrift fⁿr Kopfleiste, ▄berschriften, Versicherungsbrutto und Urlaub
  141. Dim hNormalAbz as FontType    'Schrift fⁿr Aufschlⁿsselung der gesetzlichen Abzⁿge
  142. Dim hMini as FontType
  143.  
  144. If n<10 then
  145.     hNormalB = CreateFont("Arial",8, FONT_NORMAL, COLOR_BLACK)
  146.     hNormalB2 = CreateFont("Arial",8, FONT_ITALIC, COLOR_BLACK)
  147. Else
  148.     hNormalB = CreateFont("Arial",8, FONT_NORMAL, COLOR_BLACK)
  149.     hNormalB2 = CreateFont("Arial",8, FONT_ITALIC, COLOR_BLACK)
  150. End If
  151. If m<11 then
  152.     hNormalN = CreateFont("Arial",8, FONT_NORMAL, COLOR_BLACK)
  153. Else
  154.     hNormalN = CreateFont("Arial",8, FONT_NORMAL, COLOR_BLACK)
  155. End If
  156. If m+n<22 then
  157.     hNormalAbz = CreateFont("Arial",8, FONT_NORMAL, COLOR_BLACK)
  158. Else
  159.     hNormalAbz = CreateFont("Arial",8, FONT_NORMAL, COLOR_BLACK)
  160. End If
  161.  
  162. hNormal2 = CreateFont("Arial",8, FONT_NORMAL, COLOR_BLACK)
  163. hBold = CreateFont("Arial",8, FONT_BOLD, COLOR_BLACK)
  164. ExtraBold = CreateFont("Arial",9,FONT_BOLD,COLOR_BLACK)
  165. hMini=CreateFont("Arial",7, FONT_NORMAL, COLOR_BLACK)
  166. SetFont("Arial",8,FONT_NORMAL,COLOR_BLACK)
  167. Dim FontAuskunft as FontType=CreateFont("Times New Roman",9,FONT_ITALIC,COLOR_BLACK)
  168.  
  169. Dim top as Numeric=7
  170. Dim bottom as Numeric=0
  171.  
  172.  
  173. SetPos(100,162)
  174.  
  175. LF
  176.  
  177. dim cAdressfeld as CellType=CreateCell(0,0,CELL_TYPE_DYNHORZ+CELL_TYPE_DYNVERT+CELL_TYPE_VERT)
  178. Dim cFirmenabsender as CellType=CreateCellEx (cAdressfeld,0,0,CELL_TYPE_DYNVERT+CELL_TYPE_DYNHORZ,
  179.     StrStr("F",1) + " , " + StrStr("F",2) + " , " + StrStr("F",3) + " " + StrStr("F",4),hNormal2,CELL_TEXT_LEFT,
  180.     COLOR_TRANSPARENT, hNullPen, hNullPen, hNullPen, hSolidPen, hNullPen, 0, 0, 0, 10)
  181. Dim BreiteFirmenabsender as Numeric
  182. BreiteFirmenabsender=GetCellWidth(cFirmenabsender)
  183. If BreiteFirmenabsender>800 Then
  184.     SetCellText(cFirmenabsender,StrStr("F",1) + "\n" + StrStr("F",2) + ", " + StrStr("F",3) + " " + StrStr("F",4))
  185.     SetPos(100, GetPosY()-32)
  186. End If    
  187. SetCellBorder(cFirmenabsender, CELL_BORDER_LEFT, 0, PEN_NULL, COLOR_TRANSPARENT)
  188. SetCellBorder(cFirmenabsender, CELL_BORDER_TOP, 0, PEN_NULL, COLOR_TRANSPARENT)
  189. SetCellBorder(cFirmenabsender, CELL_BORDER_RIGHT, 0, PEN_NULL, COLOR_TRANSPARENT)
  190. SetCellBorder(cFirmenabsender, CELL_BORDER_BOTTOM, 1, PEN_SOLID, COLOR_BLACK)
  191.  
  192. SetPos(100, GetPosY())
  193. DrawCell(cFirmenabsender,TRUE)
  194.  
  195. SetTabs("L100")
  196. SetPos(0,290)
  197. SetFont("Arial",10,FONT_NORMAL,COLOR_BLACK)
  198. TL("\tHerr/Frau")
  199. SetPos(0,335)
  200. TL("\t" + StrStr("P",3) + " " + StrStr("P",2))
  201. SetPos(0,390)
  202. TL("\t" + StrStr("P",4))
  203. LF
  204. TL("\t" + StrStr("P",5) + " " + StrStr("P",6))
  205.  
  206. SetPos(0,0)
  207.  
  208. Dim KopfZeilenNr as Numeric=0
  209.  
  210. Dim cKopfTop as CellType=CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  211. SetCellBorder(cKopfTop,CELL_BORDER_ALL,3,PEN_SOLID,COLOR_BLACK)
  212.  
  213. Dim cKopfRechts as CellType=CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT +CELL_TYPE_VERT )
  214.  
  215.  
  216. Function EinfgStammDaten( FeldBreite as Numeric, FeldName as String, FeldWert as String) as CellType
  217.     dim cPos as CellType=CreateCell(0,0,CELL_TYPE_DYNVERT+CELL_TYPE_DYNHORZ+CELL_TYPE_VERT) 
  218.     SetCellBackground(cPos,COLOR_WHITE)
  219.     If KopfZeilenNr=1 Then
  220.         SetCellParent(cPos, cKopfTop)
  221.     Else
  222.         SetCellParent(cPos, cell(cKopfRechts,KopfZeilenNr-1))
  223.     End If
  224.     
  225.     CreateCellEx(cPos,FeldBreite,45,CELL_TYPE_DYNVERT+CELL_TYPE_HORZ,FeldName,hNormal2,CELL_TEXT_CENTER,
  226.         COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 0, 7, 0, 0)
  227.  
  228.     CreateCellEx(cPos,FeldBreite,45,CELL_TYPE_DYNVERT,FeldWert,hNormal2,CELL_TEXT_CENTER,
  229.         COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 0, 7, 0, 0)
  230.  
  231. End Function
  232.  
  233. Dim OeffentlDienstBetrag as Numeric
  234. Dim OeffentlDienstWert as String
  235. Dim KVWert as String
  236. Dim KVSatz as String
  237. Dim PVWert as String
  238. Dim RVWert as String
  239. Dim RVWertAN as String
  240. Dim RV_AG12_RestAN as Bool
  241. Dim AVWert as String
  242. Dim RestUrlaubBetrag as Numeric
  243. Dim RestUrlaubWert as String
  244. Dim SchluesselSV as Numeric
  245. Dim SteuerklasseBetrag as Numeric
  246. Dim SteuerklasseWert as String
  247. Dim SteuerTraegt as String
  248. Dim UrlaubsAnspruchBetrag as Numeric
  249. Dim UrlaubsAnspruchWert    as String
  250. Dim WaehrungWert as String
  251.  
  252.  
  253. If Is("D",80) Then
  254.     WaehrungWert="EURO"
  255. Else
  256.     WaehrungWert="DM"
  257. End If
  258.  
  259. OeffentlDienstBetrag=GetInt("B",16)
  260. If OeffentlDienstBetrag=0 Then OeffentlDienstWert="nein"
  261. Else If OeffentlDienstBetrag=1 Then OeffentlDienstWert="Vbl / Zvk"
  262.                                          Else OeffentlDienstWert="VblU" End If
  263. End If    
  264.  
  265. SteuerklasseBetrag=GetInt("D",6)
  266.  
  267. If SteuerklasseBetrag=0 Then SteuerklasseWert="0" End If
  268. If SteuerklasseBetrag=1 Then SteuerklasseWert="I" End If
  269. If SteuerklasseBetrag=2 Then SteuerklasseWert="II" End If
  270. If SteuerklasseBetrag=3 Then SteuerklasseWert="III" End If
  271. If SteuerklasseBetrag=4 Then SteuerklasseWert="IV" End If
  272. If SteuerklasseBetrag=5 Then SteuerklasseWert="V" End If
  273. If SteuerklasseBetrag=6 Then SteuerklasseWert="VI" End If
  274.  
  275. SteuerTraegt=Get("D",104)
  276. If SteuerTraegt="AN" Then SteuerTraegt="Arbeitnehmer"
  277.                             Else SteuerTraegt="Arbeitgeber"    End If
  278.  
  279.  
  280. SchluesselSV= GetInt("D",7)
  281.  
  282. If SchluesselSV=1 Then
  283.     KVSatz=" - "+StrAmt("D",11)+" %"
  284.     KVWert=Get("D",59)
  285. End If
  286.  
  287. If SchluesselSV=9 Then KVWert="freiwillig / privat"
  288. Else
  289.     If SchluesselSV=0 OR SchluesselSV=6 Then KVWert=Get("D",57)
  290.     Else If SchluesselSV=21 Then KVWert="AG 5%" End If
  291.     End If
  292. End If
  293.  
  294.  
  295. SchluesselSV=GetInt("D",8)
  296. If SchluesselSV=1 Then RVWert="ja"
  297.  
  298. Else If SchluesselSV=0 Then    RVWert="nein"
  299.  
  300. Else    If SchluesselSV=17 Then
  301.     RV_AG12_RestAN=TRUE
  302.     RVWert="12 %"
  303.     SetFormatNumericOptions(2,"","")
  304.     RVWertAN=FormatNumeric("%0.1f", GetNumeric("R",28))+" %"
  305.     SetFormatNumericOptions(0,"","")
  306.  
  307. Else    If SchluesselSV=22 Then
  308.     RV_AG12_RestAN=TRUE
  309.     RVWert="5 %"
  310.     RVWertAN=FormatNumeric("%0.1f", GetNumeric("R",29))+" %"
  311.  
  312. Else If SchluesselSV=6 Then
  313.     RV_AG12_RestAN=TRUE
  314.     RVWert="12 %"
  315.     RVWertAN="0 %"
  316.  
  317. Else If SchluesselSV=21 Then
  318.     RV_AG12_RestAN=TRUE
  319.     RVWert="5 %"
  320.     RVWertAN="0 %"
  321.  
  322. Else RVWert="1/2 Beitrag AG" End If
  323. End If
  324. End If
  325. End If
  326. End If
  327. End If
  328.  
  329. SchluesselSV=GetInt("D",9)
  330. If SchluesselSV=1 Then AVWert="ja"
  331. Else If SchluesselSV=0 Then AVWert="nein"
  332.                               Else AVWert="1/2 Beitrag AG" End If
  333. End If
  334.  
  335.  
  336. SchluesselSV=GetInt("D",10)
  337. If SchluesselSV=1 Then PVWert="ja"
  338. Else If SchluesselSV=0 Then PVWert="nein"
  339.     Else If SchluesselSV=9 Then PVWert="freiwillig / privat"
  340.                                   Else PVWert="halber Beitrag" End If
  341.     End If
  342. End If
  343.  
  344.      
  345. RestUrlaubBetrag=GetNumeric("P",64)
  346. If RestUrlaubBetrag<>1 Then
  347.     RestUrlaubWert=StrAmt("P",64)+" Tage"
  348. Else
  349.     RestUrlaubWert=StrAmt("P",64)+" Tag"
  350. End If
  351.  
  352.  
  353. UrlaubsAnspruchBetrag=GetNumeric("P",63)
  354. If UrlaubsAnspruchBetrag<>1 Then
  355.     UrlaubsAnspruchWert=StrAmt("P",63)+" Tage"
  356. Else
  357.     UrlaubsAnspruchWert=StrAmt("P",63)+" Tag"
  358. End If
  359.  
  360.  
  361. '1. Kopfzeile
  362. KopfZeilenNr=KopfZeilenNr+1
  363. EinfgStammDaten( 230, "Personal-Nr.", StrStr("P",1))
  364. EinfgStammDaten( 710, "Name, Vorname",StrStr("P",2) +" , "+ StrStr("P",3) )
  365. EinfgStammDaten( 339, "Kostenstelle", StrStr("P",16))
  366. EinfgStammDaten( 190, "Eintritt", StrDate("P",19))
  367. EinfgStammDaten( 233, "Abrechnung", StrStr("D",60))
  368. EinfgStammDaten( 148, "WΣhrung", WaehrungWert)
  369.  
  370.  
  371.  
  372. '2.Kopfzeile
  373. KopfZeilenNr=KopfZeilenNr+1
  374. SetCellParent(CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT +CELL_TYPE_HORZ),cKopfRechts)
  375. BorderWidth(cell(cKopfRechts,KopfZeilenNr-1),3,0,3,3)
  376.  
  377. EinfgStammDaten( 222, "╓ffentl. Dienst", OeffentlDienstWert)
  378.  
  379. If (SteuerklasseBetrag>=0 AND SteuerklasseBetrag<=6) Then
  380.     
  381.     EinfgStammDaten( 117, "St.-Kl.", SteuerklasseWert) 
  382.     EinfgStammDaten( 116, "Kinder", StrKfb("D",17))
  383.     EinfgStammDaten( 159, "Kirche",StrBool("D",14))
  384.     EinfgStammDaten( 296, "Freibetrag", StrAmt("D",15)+" "+StrStr("D",115))
  385. Else
  386.     EinfgStammDaten( 233, "Besteuerung", "Pauschal")
  387.     EinfgStammDaten( 233, "Steuer trΣgt der", SteuerTraegt)
  388.     EinfgStammDaten( 222, "Steuersatz", StrAmt("D",103)+" %")
  389. End If
  390.  
  391. '3.Kopfzeile
  392. KopfZeilenNr=KopfZeilenNr+1
  393. SetCellParent(CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT +CELL_TYPE_HORZ),cKopfRechts)
  394. BorderWidth(cell(cKopfRechts,KopfZeilenNr-1),3,0,3,3)
  395. EinfgStammDaten( 222, "KV"+KVSatz, KVWert)
  396. EinfgStammDaten( 233, "PV", PVWErt)
  397. EinfgStammDaten( 233, "RV", RVWert)
  398. EinfgStammDaten( 222, "AV", AVWert)
  399.  
  400. Dim cKopfRV as CellType
  401.  
  402. If RV_AG12_RestAN=TRUE Then
  403.     cKopfRV=Cell(cell(cKopfRechts,KopfZeilenNr-1),3)
  404.     SetCellText(Cell(cKopfRV,1),"")
  405.     CreateCellEx(Cell(cKopfRV,1),76,45,CELL_TYPE_DYNVERT,"AG",hMini,CELL_TEXT_LEFT,
  406.         COLOR_TRANSPARENT, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen, 15, 10, 0, 0)
  407.     CreateCellEx(Cell(cKopfRV,1),81,45,CELL_TYPE_DYNVERT,"- RV -",hNormal2,CELL_TEXT_CENTER,
  408.         COLOR_TRANSPARENT, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen, 0, 7, 0, 0)
  409.     CreateCellEx(Cell(cKopfRV,1),76,45,CELL_TYPE_DYNVERT,"AN",hMini,CELL_TEXT_RIGHT,
  410.         COLOR_TRANSPARENT, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen, 0, 10, 15, 0)
  411.     SetCellAlign(Cell(cKopfRV,2),CELL_TEXT_LEFT)
  412.     SetCellTextBorder(Cell(cKopfRV,2),15,7,0,0)
  413.     CreateCellEx(Cell(cKopfRV,2),233,45,CELL_TYPE_DYNVERT,RVWertAN,hNormal2,CELL_TEXT_RIGHT,
  414.         COLOR_TRANSPARENT, hNullPen, hNullPen, hSolidPen, hNullPen, hNullPen, 0, 7, 15, 0)
  415. End If
  416.  
  417. '4.Kopfzeile
  418. KopfZeilenNr=KopfZeilenNr+1
  419. SetCellParent(CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT +CELL_TYPE_HORZ),cKopfRechts)
  420. BorderWidth(cell(cKopfRechts,KopfZeilenNr-1),3,0,3,3)
  421. EinfgStammDaten( 222, "KV-Brutto", StrAmt("R",13))
  422. EinfgStammDaten( 233, "PV-Brutto", StrAmt("R",22))
  423. EinfgStammDaten( 233, "RV-Brutto", StrAmt("R",14))
  424. EinfgStammDaten( 222, "AV-Brutto", StrAmt("R",15))
  425.  
  426.  
  427. '5.Kopfzeile
  428. If Is("E",5) Then
  429.     KopfZeilenNr=KopfZeilenNr+1
  430.     SetCellParent(CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT +CELL_TYPE_HORZ),cKopfRechts)
  431.     BorderWidth(cell(cKopfRechts,KopfZeilenNr-1),3,0,3,3)
  432.     EinfgStammDaten(222, "KV-Brutto"+ " "+FormatNumeric("%0.0f",GetInt("D",2)-1),StrAmt("R",16) )
  433.     EinfgStammDaten( 233, "PV-Brutto"+ " "+FormatNumeric("%0.0f",GetInt("D",2)-1),StrAmt("R",23) )
  434.     EinfgStammDaten( 233, "RV-Brutto"+ " "+FormatNumeric("%0.0f",GetInt("D",2)-1), StrAmt("R",17))
  435.     EinfgStammDaten( 222, "AV-Brutto"+ " "+FormatNumeric("%0.0f",GetInt("D",2)-1), StrAmt("R",18))
  436. End If
  437.  
  438.  
  439. '6.Kopfzeile
  440. KopfZeilenNr=KopfZeilenNr+1
  441. SetCellParent(CreateCell (910,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT +CELL_TYPE_HORZ),cKopfRechts)
  442. BorderWidth(cell(cKopfRechts,KopfZeilenNr-1),3,0,3,3)
  443.  
  444. EinfgStammDaten( 222, "Resturlaub",ResturlaubWert )
  445. EinfgStammDaten( 233, "Urlaubsanspruch", UrlaubsAnspruchWert)
  446. EinfgStammDaten( 455, "Bundesland", StrStr("D",19))
  447.  
  448.  
  449. 'BruttobetrΣge mit Aufschlⁿsselung
  450. Dim cBrutto as CellType = CreateCell (0,0,CELL_TYPE_DYNVERT + CELL_TYPE_DYNHORZ + CELL_TYPE_VERT)
  451. BorderWidth(cBrutto, 3,3,3,3)
  452. 'Dim cBezBet as CellType = CreateCell (0,0,CELL_TYPE_DYNVERT + CELL_TYPE_DYNHORZ + CELL_TYPE_HORZ)
  453. Dim cBezBet as CellType = CreateCellEx (cBrutto,1850,45,CELL_TYPE_DYNVERT + CELL_TYPE_DYNHORZ + CELL_TYPE_HORZ, StrKurs ,hNormalB,CELL_TEXT_RIGHT,
  454.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 350, 0)
  455. 'SetCellParent (cBezBet, cBrutto)
  456. 'SetCellTextBorder(cBezBet,0,0,0,0)
  457. '▄berschriften
  458. Dim cBezuege as CellType = CreateCellEx (cBezBet,1520,0,CELL_TYPE_DYNVERT,"Brutto-Bezⁿge",hBold,CELL_TEXT_LEFT,
  459.     COLOR_TRANSPARENT, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen,15 , 7, 5, 0)
  460. Dim cBetrag as CellType = CreateCellEx (cBezBet,330,0,CELL_TYPE_DYNVERT,"Betrag",hNormalB,CELL_TEXT_RIGHT,
  461.     COLOR_TRANSPARENT, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 30, 0)
  462.  
  463. 'Aufschlⁿsselung
  464. 'Zellendefinierung
  465. Dim c5Brutto as CellType=CreateCellEx (cBrutto,0,0,CELL_TYPE_DYNVERT + CELL_TYPE_DYNHORZ + CELL_TYPE_VERT,"",hNormalB,CELL_TEXT_RIGHT,
  466.     COLOR_WHITE, hNullPen, hSolidPen, hNullPen, hNullPen, hNullPen, 0, 0,0, 0)
  467.  
  468.  
  469.  
  470. 'ersten 5 Lohnarten
  471.  
  472. Dim i as Numeric=1
  473. Dim k as Numeric=0
  474. Dim p as Numeric=1
  475.  
  476. Dim BruttoHeight as Numeric
  477.  
  478. Dim cPosition as CellType
  479. Dim cLohnart as CellType
  480. Dim cKorrBetrag as CellType
  481. Dim cKorrWaehrung as CellType
  482. Dim cMenge as CellType
  483. Dim cEinheit as CellType
  484. Dim cFaktor as CellType
  485. Dim cFaktorWaehrung as CellType
  486. Dim cBruttoBetrag as CellType
  487. Dim cBruttoWaehrung as CellType
  488.  
  489. Dim cPositionLZ as CellType
  490. Dim cLohnartLZ as CellType
  491. Dim cMengeLZ as CellType
  492. Dim cEinheitLZ as CellType
  493. Dim cFaktorLZ as CellType
  494. Dim cFaktorWaehrungLZ as CellType
  495. Dim cBruttoBetragLZ as CellType
  496. Dim cBruttoWaehrungLZ as CellType
  497.  
  498. Dim stWaehrFirma as String
  499. Dim blOutputFirma as Bool
  500. Dim stLohnart as String
  501. Dim stEinheit as String
  502. Dim Menge as Numeric
  503. Dim NumBruttoBetrag as Numeric
  504. Dim NumPauschAnteilDV as Numeric
  505. Dim stKorrBetrag as String
  506. Dim stKorrWaehrung as String
  507. Dim stMenge as String
  508. Dim stFaktor as String
  509. Dim stFaktorWaehrung as String
  510. Dim stBruttoBetrag as String
  511. Dim stBruttoWaehrung as String
  512. Dim StrPauschAnteilDV as String=""
  513.  
  514. blOutputFirma=Is("D",81)
  515.  
  516. If Is("D",80) Then stWaehrFirma="EUR"
  517. Else stWaehrFirma="DM"
  518. End If
  519.  
  520.  
  521. Function KorrDMnachEUR(LohnartBetrag as Numeric) As String
  522.     KorrDMnachEUR=FormatAmt(LohnartBetrag/1.95583) 
  523. End Function
  524.  
  525.  
  526. Function KorrEURnachDM(LohnartBetrag as Numeric) As String
  527.     If LohnartBetrag>=0 Then
  528.         KorrEURnachDM=FormatAmt(LohnartBetrag*1.95583+0.00000002)
  529.    Else
  530.         KorrEURnachDM=FormatAmt(LohnartBetrag*1.95583-0.00000002)
  531.     End If
  532. End Function
  533.  
  534.  
  535. Function EinfgLohnart(Lohnart as String,s as String, n as Numeric)
  536.     k=k+1
  537.     If k<>1 Then
  538.         DuplicateCell(cPosition)
  539.     End If
  540.     
  541.     If s<>"" Then
  542.         stBruttoBetrag=StrAmt(s,n)
  543.         stBruttoWaehrung=StrStr(s,100+n)
  544.         If stWaehrFirma<>stBruttoWaehrung Then
  545.             If stBruttoWaehrung="DM" Then
  546.                 stKorrBetrag=KorrDMnachEUR(GetNumeric(s,n))
  547.                 stKorrWaehrung=" EUR"
  548.             Else
  549.                 stKorrBetrag=KorrEURnachDM(GetNumeric(s,n))
  550.                 stKorrWaehrung=" DM"
  551.             End If
  552.         Else
  553.             stKorrBetrag=""
  554.             stKorrWaehrung=""
  555.         End If
  556.     Else
  557.         stKorrBetrag=""
  558.         stKorrWaehrung=""
  559.         stBruttoBetrag=""
  560.         stBruttoWaehrung=""
  561.     End If
  562.  
  563.     SetCellText(Cell(Cell(c5Brutto, k),1), Lohnart)
  564.     If (blOutputFirma=FALSE) AND (stKorrWaehrung<>"") Then
  565.         SetCellText(Cell(Cell(c5Brutto, k),8), stKorrBetrag)
  566.         SetCellText(Cell(Cell(c5Brutto, k),9), stKorrWaehrung)
  567.         SetCellText(Cell(Cell(c5Brutto, k),2), stBruttoBetrag)
  568.         SetCellText(Cell(Cell(c5Brutto, k),3), " "+stBruttoWaehrung)
  569.     Else
  570.         SetCellText(Cell(Cell(c5Brutto, k),2), stKorrBetrag)
  571.         SetCellText(Cell(Cell(c5Brutto, k),3), stKorrWaehrung)
  572.         SetCellText(Cell(Cell(c5Brutto, k),8), stBruttoBetrag)
  573.         SetCellText(Cell(Cell(c5Brutto, k),9), " "+stBruttoWaehrung)
  574.     End If
  575. End Function    
  576.  
  577.  
  578. Function EinfgLohnartOhneWert(TextLohnart as String, Bereich as String, NrBereich as Numeric)
  579.         stBruttoWaehrung=StrStr(Bereich, (NrBereich+100))
  580.         stlohnart=TextLohnart+" ( "+StrAmt(Bereich,NrBereich)+" "+stBruttoWaehrung
  581.         
  582.         If stWaehrFirma<>stBruttoWaehrung Then
  583.             
  584.             If stBruttoWaehrung="DM" Then
  585.                 stKorrBetrag=KorrDMnachEUR(GetNumeric(Bereich,NrBereich))
  586.                 stKorrWaehrung=" EUR"
  587.             Else
  588.                 stKorrBetrag=KorrEURnachDM(GetNumeric(Bereich,NrBereich))
  589.                 stKorrWaehrung=" DM"
  590.             End If
  591.  
  592.             stlohnart=stlohnart+" / "+stKorrBetrag+stKorrWaehrung
  593.             
  594.         End IF
  595.         
  596.         stlohnart=stlohnart+" )"
  597.         stBruttoWaehrung=""
  598.         stKorrBetrag=""
  599.         stKorrWaehrung=""
  600.  
  601.         EinfgLohnart(stLohnart,"",0)
  602.  
  603. End Function
  604.  
  605.  
  606.  
  607. cPosition=CreateCellEx (c5Brutto,0,0,CELL_TYPE_DYNVERT+CELL_TYPE_HORZ,"",hNormalB,CELL_TEXT_LEFT,
  608.                 COLOR_WHITE, hSolidPen, hNullPen, hNullPen, hNullPen, hNullPen,0, 0, 0, 0)
  609.             
  610. cLohnart=CreateCellEx (cPosition,1190,0,CELL_TYPE_DYNVERT,stLohnart,hNormalB,CELL_TEXT_LEFT,
  611.     COLOR_WHITE, hSolidPen, hNullPen, hNullPen, hNullPen, hNullPen,15, 3, 5, 0)
  612.             
  613. cKorrBetrag=CreateCellEx (cPosition,250,0,CELL_TYPE_DYNVERT,stKorrBetrag,hNormalB,CELL_TEXT_RIGHT,
  614.     COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen,5, 3, 0, 0)
  615.  
  616. cKorrWaehrung=CreateCellEx (cPosition,80,0,CELL_TYPE_DYNVERT,stKorrWaehrung,hNormalB,CELL_TEXT_LEFT,
  617.     COLOR_WHITE, hNullPen, hNullPen, hSolidPen, hNullPen, hNullPen,0, 3, 5, 0)
  618.  
  619. cMenge=CreateCellEx (cPosition,0,0,CELL_TYPE_DYNVERT,stmenge,hNormalB,CELL_TEXT_RIGHT,
  620.         COLOR_WHITE, hSolidPen, hNullPen, hNullPen, hNullPen, hNullPen,5, 3, 0, 0)
  621.     
  622. cEinheit=CreateCellEx (cPosition,0,0,CELL_TYPE_DYNVERT,stEinheit,hNormalB,CELL_TEXT_LEFT,
  623.         COLOR_WHITE, hNullPen, hNullPen, hSolidPen, hNullPen, hNullPen,0, 3, 5, 0)
  624.     
  625. cFaktor=CreateCellEx (cPosition,0,0,CELL_TYPE_DYNVERT,stFaktor,hNormalB,CELL_TEXT_RIGHT,
  626.         COLOR_WHITE, hSolidPen, hNullPen, hNullPen, hNullPen, hNullPen,5, 3, 0, 0)
  627.     
  628. cFaktorWaehrung=CreateCellEx (cPosition,0,0,CELL_TYPE_DYNVERT,stFaktorWaehrung,hNormalB,CELL_TEXT_LEFT,
  629.         COLOR_WHITE, hNullPen, hNullPen, hSolidPen, hNullPen, hNullPen,0, 3, 5, 0)
  630.                             
  631. cBruttoBetrag=CreateCellEx (cPosition,250,0,CELL_TYPE_DYNVERT,stBruttoBetrag,hNormalB,CELL_TEXT_RIGHT,
  632.     COLOR_WHITE, hSolidPen, hNullPen, hNullPen, hNullPen, hNullPen,5, 3, 0, 0)
  633.  
  634. cBruttoWaehrung=CreateCellEx (cPosition,80,0,CELL_TYPE_DYNVERT,stBruttoWaehrung,hNormalB,CELL_TEXT_LEFT,
  635.     COLOR_WHITE, hNullPen, hNullPen, hSolidPen, hNullPen, hNullPen,0, 3, 5, 0)
  636.  
  637.  
  638.  
  639. If Is("D",61) then
  640.  
  641.     While i<=5 do
  642.         
  643.         If Is("D",71+i) Then
  644.             
  645.             k=k+1
  646.  
  647.             If Is("D",82+i) Then
  648.                 
  649.     '            stLohnart=StrStr("D",66+i)
  650.                 
  651.                 stMenge=StrAmt("D",92+i)
  652.             
  653.                 stEinheit=StrInt("D",87+i)
  654.                 Menge=GetNumeric("D",92+i)
  655.                 
  656.                 If stEinheit="0" Then
  657.                     stEinheit="Std"
  658.                 Else
  659.                     If stEinheit="1" Then
  660.                         stEinheit="Stⁿck"
  661.                     Else
  662.                         If Menge=1 Then
  663.                         stEinheit="Tag"
  664.                         Else
  665.                             stEinheit="Tage"
  666.                         End IF
  667.                     End If
  668.                 End If
  669.                 
  670.                 stFaktor=StrAmt("D",97+i)
  671.                 stFaktorWaehrung=" "+StrStr("D",161+i)
  672.                 stLohnart=stMenge+" "+stEinheit+" "+"α"+" "+stFaktor+stFaktorWaehrung
  673.                 
  674.             Else        
  675.                 stLohnart=StrStr("D",66+i)
  676.                 
  677. '                If ((i=5) AND Is("D",54)) Then
  678. '                    
  679. '                    NumPauschAnteilDV=GetNumeric("A",51)
  680. '                    
  681. '                    If ((stLohnart="Barlohnumwandlung fⁿr Direktversicherung") AND (NumPauschAnteilDV>0)) Then
  682. '
  683. '                        stLohnart=stLohnart+" ( -"+FormatAmt(NumPauschAnteilDV-GetNumeric("A",46))+" + nicht pausch. Anteil "+FormatAmt(NumPauschAnteilDV)+" )" 
  684. '
  685. '                    End If
  686. '
  687. '                End If
  688.  
  689.                 If stLohnart="" Then stLohnart="Bruttogehalt "+FormatNumeric("%0.0f",i) End If
  690.                 stMenge=""
  691.                 stEinheit=""
  692.                 stFaktor=""
  693.                 stFaktorWaehrung=""
  694.             End If    
  695.             
  696.  
  697.             NumBruttoBetrag=GetNumeric("D",61+i)
  698.             stBruttoWaehrung=StrStr("D",161+i)
  699.             stBruttoBetrag=FormatAmt(NumBruttoBetrag)
  700.             
  701.             If (stWaehrFirma<>stBruttoWaehrung) Then
  702.                 If stBruttoWaehrung="DM" Then
  703.                     stKorrBetrag=KorrDMnachEUR(NumBruttoBetrag)
  704.                     stKorrWaehrung=" EUR"
  705.                 Else
  706.                     stKorrBetrag=KorrEURnachDM(NumBruttoBetrag)
  707.                     stKorrWaehrung=" DM"
  708.                 End If
  709.             Else
  710.                 stKorrBetrag=""
  711.                 stKorrWaehrung=""
  712.             End If
  713.             
  714.             If (i=5) Then
  715.                 If (stLohnart="Barlohnumwandlung fⁿr Direktversicherung") Then StrPauschAnteilDV="Barlohnumwandlung" End If
  716.                 If (stLohnart="Nicht pauschaler Anteil der DV-Zusatzleistung") Then StrPauschAnteilDV="Zusatzleistung" End If
  717.             End If
  718.  
  719.             If ((i<5) OR (StrPauschAnteilDV="")) Then
  720.  
  721.                 If (k<>1) Then
  722.                     DuplicateCell(cPosition)
  723.                 End If
  724.                     
  725.                 SetCellText(Cell(Cell(c5Brutto, k),1),stLohnart)
  726.                 
  727.     '            SetCellText(Cell(Cell(c5Brutto, k),4),stMenge )
  728.     '            SetCellText(Cell(Cell(c5Brutto, k),5),stEinheit )
  729.     '            SetCellText(Cell(Cell(c5Brutto, k),6),stFaktor )
  730.     '            SetCellText(Cell(Cell(c5Brutto, k),7),stFaktorWaehrung )
  731.                 
  732.                 If (blOutputFirma=FALSE) AND (stKorrWaehrung<>"") Then
  733.                     SetCellText(Cell(Cell(c5Brutto, k),8),stKorrBetrag)
  734.                     SetCellText(Cell(Cell(c5Brutto, k),9),stKorrWaehrung)
  735.                     SetCellText(Cell(Cell(c5Brutto, k),2),stBruttoBetrag )
  736.                     SetCellText(Cell(Cell(c5Brutto, k),3)," "+stBruttoWaehrung)
  737.                 Else
  738.                     SetCellText(Cell(Cell(c5Brutto, k),2),stKorrBetrag)
  739.                     SetCellText(Cell(Cell(c5Brutto, k),3),stKorrWaehrung)
  740.                     SetCellText(Cell(Cell(c5Brutto, k),8),stBruttoBetrag )
  741.                     SetCellText(Cell(Cell(c5Brutto, k),9)," "+stBruttoWaehrung)
  742.                 End If
  743.             
  744.             Else
  745.                 
  746.                 k=k-1
  747.     
  748.             End If
  749.  
  750.         End If
  751.         i=i+1
  752.     End While
  753.     
  754. Else 
  755.     'wenn nur ein Gehalt vorhanden ist    
  756.     EinfgLohnart("Bruttogehalt","D",5)
  757. End If
  758.  
  759.  
  760. 'Einmalzahlung        
  761. Dim EZArtInt as Numeric
  762. Dim EZArt as String
  763. If is("E",1) then
  764.     EZArt=StrStr("E",29)
  765.     EZArtInt=GetInt("E",36)
  766.     If EZArt="" Then 
  767.         If EZArtInt=0 Then EZArt="Einmalzahlung"
  768.         Else If EZArtInt=1 Then EZArt="Abfindung"
  769.                Else EZArt="MehrjΣhrige Vergⁿtung"
  770.                End If
  771.         End If
  772.     Else EZArt=StrStr("E",29)
  773.     End If
  774.     EinfgLohnart(EZArt,"E",2)
  775. End If
  776.  
  777. 'Direktversicherung
  778. If is("D",21) then
  779.     stlohnart=StrStr("D",56)
  780.     NumPauschAnteilDV=GetNumeric("A",51)
  781.     
  782.     If Is("D",55) then
  783.         If (NumPauschAnteilDV>0) Then
  784.             EinfgLohnartOhneWert("Nicht pauschaler Anteil DV-Einmalzahlung","A",51)
  785.         End If
  786.         EinfgLohnartOhneWert("Direktversicherung aus Einmalzahlung","B",4)
  787.     End if
  788.  
  789.     If Is("D",54) Then
  790.         If NumPauschAnteilDV>0 Then
  791.             stLohnart="Barlohnumwandlung fⁿr Direktversicherung"+" ( -"+FormatAmt(NumPauschAnteilDV-GetNumeric("A",46))+" + nicht pausch. Anteil "+FormatAmt(NumPauschAnteilDV)+" )" 
  792.             EinfgLohnart(stLohnart,"D",66)
  793.             stLohnart="Direktversicherung als Barlohnumwandlung"+" ( "+FormatAmt(NumPauschAnteilDV-GetNumeric("A",46))+" - nicht pausch. Anteil "+FormatAmt(-NumPauschAnteilDV)+" )"
  794.             EinfgLohnart(stLohnart,"B",4)
  795.         Else
  796.             EinfgLohnart("Barlohnumwandlung fⁿr Direktversicherung","D",66)
  797.             EinfgLohnart("Direktversicherung als Barlohnumwandlung","B",4)
  798.         End If
  799.         
  800.     End If
  801.  
  802.     If Is("D",53) Then
  803.         stLohnart="Direktversicherung als Zusatzleistung"
  804.         If StrPauschAnteilDV="Zusatzleistung" Then
  805.             EinfgLohnart("Nicht pauschaler Anteil der DV-Zusatzleistung","A",51)
  806.         End If
  807.         EinfgLohnart(stLohnart,"B",4)
  808.     End If
  809.  
  810. End If
  811.  
  812.  
  813.  
  814. '        If (Is("D",54) AND (NumPauschAnteilDV>0)) Then
  815. '            stLohnart=stLohnart+" ( "+FormatAmt(NumPauschAnteilDV-GetNumeric("A",46))+" - nicht pausch. Anteil "+FormatAmt(-NumPauschAnteilDV)+" )" 
  816. '        End if
  817. '
  818. '        EinfgLohnart(stLohnart,"B",4)
  819. '    End If
  820. 'End If
  821.  
  822. 'Verm÷genswirksame Leistungen
  823. If is("D",26) then
  824.     EinfgLohnart("Verm÷genswirksame Leistungen","B",2)
  825. End If
  826.  
  827. 'Dienstwagen
  828. If is("D",20) then
  829.     If is("D",52) then
  830.         stLohnart="Dienstwagen (davon pauschal versteuert durch AG "+StrAmt("B",12)+")"
  831.     else
  832.         stLohnart="Dienstwagen"
  833.     End If
  834.     EinfgLohnart(stLohnart,"B",1)
  835. End If
  836.  
  837. '1.-3. Geldwerter Vorteil
  838. While p<=3 Do
  839.     If is("D",22+p) then
  840.         stLohnart=StrStr("D",32+p)
  841.         If stLohnart="" Then stLohnart="Geldwerter Vorteil "+FormatNumeric("%0.0f",p) End If
  842.         EinfgLohnart(stLohnart,"B",7+p)
  843.     End If
  844.     p=p+1
  845. End While
  846.  
  847. 'Fahrgeld
  848. If Is("D",22) Then
  849.     If GetInt("D",51)<>2 Then
  850.         EinfgLohnart("Fahrgeld","B",11)
  851.     End If
  852. End If
  853.  
  854. Dim Bruttehoehe as Numeric
  855. Bruttehoehe=(13*GetCellHeight(Cell(Cell(c5Brutto, 1),1)))+17
  856.  
  857. SetCellTextBorder(Cell(Cell(c5Brutto, 1),1),15, 10, 5, 0)
  858. SetCellTextBorder(Cell(Cell(c5Brutto, 1),2),5, 10, 0, 0)
  859. SetCellTextBorder(Cell(Cell(c5Brutto, 1),3),0, 10, 5, 0)
  860. SetCellTextBorder(Cell(Cell(c5Brutto, 1),4),5, 10, 0, 0)
  861. SetCellTextBorder(Cell(Cell(c5Brutto, 1),5),0, 10, 5, 0)
  862. SetCellTextBorder(Cell(Cell(c5Brutto, 1),6),5, 10, 0, 0)
  863. SetCellTextBorder(Cell(Cell(c5Brutto, 1),7),0, 10, 5, 0)
  864. SetCellTextBorder(Cell(Cell(c5Brutto, 1),8),5, 10, 0, 0)
  865. SetCellTextBorder(Cell(Cell(c5Brutto, 1),9),0, 10, 5, 0)
  866.  
  867.  
  868.  
  869. BruttoHeight=GetCellHeight(c5Brutto)
  870.  
  871.  
  872. Dim cBruttoLZ as CellType=CreateCellEx (cBrutto,0,Bruttehoehe-BruttoHeight,CELL_TYPE_DYNHORZ + CELL_TYPE_VERT,"",hNormalB,CELL_TEXT_RIGHT,
  873.     COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen, 0, 0,0, 0)
  874.  
  875.  
  876. cPositionLZ=CreateCellEx (cBruttoLZ,0,Bruttehoehe-BruttoHeight,CELL_TYPE_DYNHORZ+CELL_TYPE_HORZ,"",hNormalB,CELL_TEXT_LEFT,
  877.                 COLOR_WHITE, hSolidPen, hNullPen, hNullPen, hNullPen, hNullPen,0, 0, 0, 0)
  878.             
  879. cLohnartLZ=CreateCellEx (cPositionLZ,1520,Bruttehoehe-BruttoHeight,CELL_TYPE_DYNVERT,"",hNormalB,CELL_TEXT_LEFT,
  880.     COLOR_WHITE, hSolidPen, hNullPen, hNullPen, hNullPen, hNullPen,15, 10, 5, 0)
  881.             
  882. cMengeLZ=CreateCellEx (cPositionLZ,0,Bruttehoehe-BruttoHeight,CELL_TYPE_DYNVERT,"",hNormalB,CELL_TEXT_RIGHT,
  883.         COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen,5, 10, 0, 0)
  884.     
  885. cEinheitLZ=CreateCellEx (cPositionLZ,0,Bruttehoehe-BruttoHeight,CELL_TYPE_DYNVERT,"",hNormalB,CELL_TEXT_LEFT,
  886.         COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen,0, 10, 5, 0)
  887.     
  888. cFaktorLZ=CreateCellEx (cPositionLZ,0,Bruttehoehe-BruttoHeight,CELL_TYPE_DYNVERT,"",hNormalB,CELL_TEXT_RIGHT,
  889.         COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen,5, 10, 0, 0)
  890.     
  891. cFaktorWaehrungLZ=CreateCellEx (cPositionLZ,0,Bruttehoehe-BruttoHeight,CELL_TYPE_DYNVERT,"",hNormalB,CELL_TEXT_LEFT,
  892.         COLOR_WHITE, hNullPen, hNullPen, hSolidPen, hNullPen, hNullPen,0, 10, 5, 0)
  893.                             
  894. cBruttoBetragLZ=CreateCellEx (cPositionLZ,240,Bruttehoehe-BruttoHeight,CELL_TYPE_DYNVERT,"",hNormalB,CELL_TEXT_RIGHT,
  895.     COLOR_WHITE, hSolidPen, hNullPen, hNullPen, hNullPen, hNullPen,5, 10, 0, 0)
  896.  
  897. cBruttoWaehrungLZ=CreateCellEx (cPositionLZ,80,Bruttehoehe-BruttoHeight,CELL_TYPE_DYNVERT,"",hNormalB,CELL_TEXT_LEFT,
  898.     COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen,0, 10, 5, 0)
  899.  
  900.  
  901. 'Ende Aufschlⁿsselung    
  902.  
  903. 'Gesamt-Brutto
  904. Dim cStSVGBrutto as CellType=CreateCell (0,0, CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT +CELL_TYPE_HORZ)
  905. SetCellBorder(cStSVGBrutto,CELL_BORDER_LEFT,0,PEN_NULL,COLOR_BLACK)
  906. SetCellBorder(cStSVGBrutto,CELL_BORDER_RIGHT,3,PEN_SOLID,COLOR_BLACK)
  907. SetCellTextBorder(cStSVGBrutto,0,0,0,0)
  908. Dim cUeberschriftStSV as CellType=CreateCellEx(cStSVGBrutto,1520,0,  CELL_TYPE_DYNVERT, "Steuer / Sozialversicherung", hBold, CELL_TEXT_LEFT,
  909.     COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen, 15, 40, 5, 0)  
  910. 'SetCellBorder(cUeberschriftStSV,CELL_BORDER_LEFT,3,PEN_SOLID,COLOR_BLACK)
  911. Dim cGBrutto as CellType = CreateCell (330,0,  CELL_TYPE_DYNVERT + CELL_TYPE_VERT)
  912. SetCellParent(cGBrutto,cStSVGBrutto)
  913. 'SetCellBorder(cGBrutto,CELL_BORDER_RIGHT,3,PEN_SOLID,COLOR_BLACK)
  914. SetCellTextBorder(cGBrutto,0,0,0,0)
  915. Dim cGesBrutto as CellType = CreateCellEx (cGBrutto,330,0,CELL_TYPE_DYNVERT,"Gesamt-Brutto",hNormal2,CELL_TEXT_RIGHT,
  916.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  917. 'SetCellTextBorder(cGesBrutto,0,0,0,0)
  918. BorderWidth(cGBrutto,3,0,0,0)
  919. 'Dim cWGBrutto as CellType = CreateCell (330,0, CELL_TYPE_DYNVERT )
  920. 'SetCellTextBorder(cWGBrutto,0,0,0,0)
  921. 'BorderWidth(cWGBrutto,3,0,3,0)
  922. Dim cWGesBrutto as CellType = CreateCellEx (cGBrutto,330,0,CELL_TYPE_DYNVERT,MinusAbsetzen(GetNumeric("R",12))+" "+StrStr("R",112),
  923.     hBold,CELL_TEXT_RIGHT,COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 0, 10, 15, 5)
  924. SetCellParent(cWGesBrutto,cGBrutto)
  925.  
  926.  
  927. 'steuerrechtliche Abzⁿge (Aufschlⁿsselung)
  928. Dim cAbzuegeSt as CellType = CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT + CELL_TYPE_VERT)
  929. BorderWidth(cAbzuegeSt,3,3,3,3)
  930. Dim cVerschAbzSt as CellType = CreateCell (1850,0,CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  931. SetCellParent (cVerschAbzSt,cAbzuegeSt)
  932. SetCellTextBorder(cVerschAbzSt,0,0,0,0)
  933. Dim cStBruttoW as Numeric=380
  934. Dim cLohnsteuerW as Numeric=380
  935. Dim cSolZW as Numeric=380
  936. Dim cKiStW as Numeric=380
  937.  
  938.  
  939. Dim cStBrutto as CellType = CreateCellEx (cVerschAbzSt,cStBruttoW,0,CELL_TYPE_DYNVERT,"Steuer-Brutto",hNormal2,CELL_TEXT_RIGHT,
  940.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  941. Dim cLohnsteuer as CellType = CreateCellEx (cVerschAbzSt,cLohnsteuerW,0,CELL_TYPE_DYNVERT,"Lohnsteuer",hNormal2,CELL_TEXT_RIGHT,
  942.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  943. Dim cSolZ as CellType = CreateCellEx (cVerschAbzSt,cSolZW,0,CELL_TYPE_DYNVERT,"SolZ",hNormal2,CELL_TEXT_RIGHT,
  944.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15,0 )
  945. Dim cKiSt as CellType = CreateCellEx (cVerschAbzSt,cKiStW,0,CELL_TYPE_DYNVERT,"KiSt",hNormal2,CELL_TEXT_RIGHT,
  946.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  947. Dim cGesAbzSt as CellType = CreateCellEx (cVerschAbzSt,330,0,CELL_TYPE_DYNVERT,"Steuerrechtliche Abzⁿge",hNormal2,CELL_TEXT_RIGHT,
  948.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)    
  949.  
  950. SetCellBorder(cGesAbzSt,CELL_BORDER_LEFT,3,PEN_SOLID,COLOR_BLACK)
  951.  
  952. 'Werte der steuerrechtlichen Abzⁿge
  953. Dim cWVerschAbzSt as CellType = CreateCell (1850,0,CELL_TYPE_DYNVErt + CELL_TYPE_HORZ)
  954. SetCellParent (cWVerschAbzSt,cAbzuegeSt)
  955. SetCellTextBorder(cWVerschAbzSt,0,0,0,0)
  956. SetCellBorder(cWVerschAbzSt,CELL_BORDER_BOTTOM,0,PEN_NULL,COLOR_BLACK)
  957. Dim cWStBrutto as CellType = CreateCellEx (cWVerschAbzSt,cStBruttoW,0,CELL_TYPE_DYNVERT,StrAmt("S",1)+" "+StrStr("S",122),hNormalAbz,CELL_TEXT_RIGHT,
  958.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen, 5, 10, 15, 0)
  959. Dim cWLohnsteuer as CellType = CreateCellEx (cWVerschAbzSt,cLohnsteuerW,0,CELL_TYPE_DYNVERT,StrAmt("S",7)+" "+StrStr("S",122),hNormalAbz,CELL_TEXT_RIGHT,
  960.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen, 5, 10, 15, 0)
  961. Dim cWSolZ as CellType = CreateCellEx (cWVerschAbzSt,cSolZW,0,CELL_TYPE_DYNVERT,StrAmt("S",25)+" "+StrStr("S",122),hNormalAbz,CELL_TEXT_RIGHT,
  962.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen,5, 10, 15, 0)
  963. Dim cWKiSt as CellType = CreateCellEx (cWVerschAbzSt,cKiStW,0,CELL_TYPE_DYNVERT,StrAmt("S",10)+" "+StrStr("S",122),hNormalAbz,CELL_TEXT_RIGHT,
  964.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen, 5, 10, 15, 0)    
  965. Dim GesAbzSt as Numeric
  966. GesAbzSt=GetNumeric("S",7)+GetNumeric("S",25)+GetNumeric("S",10)
  967. Dim cWGesAbzSt as CellType = CreateCellEx (cWVerschAbzSt,330,0,CELL_TYPE_DYNVERT,FormatAmt(GesAbzSt)+" "+StrStr("S",122),
  968.     hNormalAbz,CELL_TEXT_RIGHT,COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 0)    
  969.  
  970. SetCellBorder(cWGesAbzSt,CELL_BORDER_LEFT,3,PEN_SOLID,COLOR_BLACK)
  971.  
  972. Dim cWVerschAbzStEZ as CellType = CreateCell (1850,30,CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  973. SetCellParent (cWVerschAbzStEZ,cAbzuegeSt)
  974. SetCellBorder(cWVerschAbzStEZ,CELL_BORDER_TOP,0,PEN_NULL,COLOR_BLACK)
  975. Dim cWStBruttoEZ as CellType = CreateCellEx (cWVerschAbzStEZ,cStBruttoW,0,CELL_TYPE_DYNVERT,"",hNormalAbz,CELL_TEXT_RIGHT,
  976.     COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 10)
  977. Dim cWLohnsteuerEZ as CellType = CreateCellEx (cWVerschAbzStEZ,cLohnsteuerW,0,CELL_TYPE_DYNVERT,"",hNormalAbz,CELL_TEXT_RIGHT,
  978.     COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 10)
  979. Dim cWSolZEZ as CellType = CreateCellEx (cWVerschAbzStEZ,cSolZW,0,CELL_TYPE_DYNVERT,"",hNormalAbz,CELL_TEXT_RIGHT,
  980.     COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen,5, 10, 15, 10)
  981. Dim cWKiStEZ as CellType = CreateCellEx (cWVerschAbzStEZ,cKiStW,0,CELL_TYPE_DYNVERT,"",hNormalAbz,CELL_TEXT_RIGHT,
  982.     COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 10)    
  983. Dim GesAbzStEZ as Numeric
  984. GesAbzStEZ=GetNumeric("S",8)+GetNumeric("S",26)+GetNumeric("S",11)
  985. Dim cWGesAbzStEZ as CellType = CreateCellEx (cWVerschAbzStEZ,330,0,CELL_TYPE_DYNVERT,"",
  986.     hNormalAbz,CELL_TEXT_RIGHT,COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 10)    
  987. SetCellBorder(cWGesAbzStEZ,CELL_BORDER_TOP,0,PEN_NULL,COLOR_BLACK)
  988. SetCellBorder(cWGesAbzStEZ,CELL_BORDER_LEFT,3,PEN_SOLID,COLOR_BLACK)
  989.  
  990. 'Fⁿr den Fall, da▀ die MΣrzklausel zum Tragen kommt
  991. If is("E",1) then 
  992.             SetCellText(cWStBruttoEZ, StrAmt("S",2)+" "+StrStr("S",123))
  993.             SetCellText(cWLohnsteuerEZ, StrAmt("S",8)+" "+StrStr("S",123))
  994.             SetCellText(cWSolZEZ, StrAmt("S",26)+" "+StrStr("S",123))
  995.             SetCellText(cWKiStEZ, StrAmt("S",11)+" "+StrStr("S",123))
  996.             SetCellText(cWGesAbzStEZ,FormatAmt(GesAbzStEZ)+" "+StrStr("S",123))
  997. End If
  998. 'Ende Aufschlⁿsselung
  999.  
  1000. 'SV-rechtliche Abzⁿge (Aufschlⁿsselung)
  1001. Dim cAbzuegeSV as CellType = CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT + CELL_TYPE_VERT)
  1002. BorderWidth(cAbzuegeSV,3,0,3,3)
  1003. Dim cVerschAbzSV as CellType = CreateCell (1850,0,CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  1004. SetCellParent (cVerschAbzSV,cAbzuegeSV)
  1005. SetCellTextBorder(cVerschAbzSV,0,0,0,0)
  1006. Dim cSVBruttoW as Numeric=304
  1007. Dim cZVKBruttoW as Numeric=0
  1008. Dim cAbzKVW as Numeric=304
  1009. Dim cAbzPVW as Numeric=304
  1010. Dim cAbzRVW as Numeric=304
  1011. Dim cAbzAVW as Numeric=304
  1012.  
  1013. If Getint("B",16)<>0 Then
  1014.     cSVBruttoW=260
  1015.     cZVKBruttoW=260
  1016.     cAbzKVW=250
  1017.     cAbzPVW=250
  1018.     cAbzRVW=250
  1019.     cAbzAVW=250
  1020. end if
  1021.  
  1022. Dim cSVBrutto as CellType = CreateCellEx (cVerschAbzSV,cSVBruttoW,0,CELL_TYPE_DYNVERT,"SV-Brutto",hNormal2,CELL_TEXT_RIGHT,
  1023.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 0, 7, 15, 0)
  1024. Dim cZVKBrutto as CellType = CreateCellEx (cVerschAbzSV,cZVKBruttoW,0,CELL_TYPE_DYNVERT,"ZVK-Brutto",hNormal2,CELL_TEXT_RIGHT,
  1025.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  1026. Dim cAbzKV as CellType = CreateCellEx (cVerschAbzSV,cAbzKVW,0,CELL_TYPE_DYNVERT,"KV",hNormal2,CELL_TEXT_RIGHT,
  1027.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  1028. Dim cAbzPV as CellType = CreateCellEx (cVerschAbzSV,cAbzPVW,0,CELL_TYPE_DYNVERT,"PV",hNormal2,CELL_TEXT_RIGHT,
  1029.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  1030. Dim cAbzRV as CellType = CreateCellEx (cVerschAbzSV,cAbzRVW,0,CELL_TYPE_DYNVERT,"RV",hNormal2,CELL_TEXT_RIGHT,
  1031.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  1032. Dim cAbzAV as CellType = CreateCellEx (cVerschAbzSV,cAbzAVW,0,CELL_TYPE_DYNVERT,"AV",hNormal2,CELL_TEXT_RIGHT,
  1033.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  1034. Dim cGesAbzSV as CellType = CreateCellEx (cVerschAbzSV,330,0,CELL_TYPE_DYNVERT,"SV-rechtliche Abzⁿge",hNormal2,CELL_TEXT_RIGHT,
  1035.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)    
  1036.  
  1037. SetCellBorder(cGesAbzSV,CELL_BORDER_LEFT,3,PEN_SOLID,COLOR_BLACK)
  1038.  
  1039.  
  1040. 'Werte der SV-rechtlichen Abzⁿge
  1041. Dim cWVerschAbzSV as CellType = CreateCell (1850,0,CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  1042. SetCellParent (cWVerschAbzSV,cAbzuegeSV)
  1043. SetCellTextBorder(cWVerschAbzSV,0,0,0,0)
  1044. SetCellBorder(cWVerschAbzSV,CELL_BORDER_BOTTOM,0,PEN_NULL,COLOR_BLACK)
  1045. Dim cWSVBrutto as CellType = CreateCellEx (cWVerschAbzSV,cSVBruttoW,0,CELL_TYPE_DYNVERT,StrAmt("S",4)+" "+StrStr("S",122),hNormalAbz,CELL_TEXT_RIGHT,
  1046.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen, 5, 10, 15, 0)
  1047. Dim cWZVKBrutto as CellType = CreateCellEx (cWVerschAbzSV,cZVKBruttoW,0,CELL_TYPE_DYNVERT,StrAmt("R",26)+" "+StrStr("S",122),hNormalAbz,CELL_TEXT_RIGHT,
  1048.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen,5, 10, 15, 0)
  1049. Dim cWAbzKV as CellType = CreateCellEx (cWVerschAbzSV,cAbzKVW,0,CELL_TYPE_DYNVERT,StrAmt("S",13)+" "+StrStr("S",122),hNormalAbz,CELL_TEXT_RIGHT,
  1050.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen, 5, 10, 15, 0)
  1051. Dim cWAbzPV as CellType = CreateCellEx (cWVerschAbzSV,cAbzPVW,0,CELL_TYPE_DYNVERT,StrAmt("S",28)+" "+StrStr("S",122),hNormalAbz,CELL_TEXT_RIGHT,
  1052.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen, 5, 10, 15, 0)
  1053. Dim cWAbzRV as CellType = CreateCellEx (cWVerschAbzSV,cAbzRVW,0,CELL_TYPE_DYNVERT,StrAmt("S",16)+" "+StrStr("S",122),hNormalAbz,CELL_TEXT_RIGHT,
  1054.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen, 5, 10, 15, 0)
  1055. Dim cWAbzAV as CellType = CreateCellEx (cWVerschAbzSV,cAbzAVW,0,CELL_TYPE_DYNVERT,StrAmt("S",19)+" "+StrStr("S",122),hNormalAbz,CELL_TEXT_RIGHT,
  1056.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen, 5, 10, 15, 0)
  1057. Dim GesAbzSV as Numeric
  1058. GesAbzSV=GetNumeric("S",13)+GetNumeric("S",28)+GetNumeric("S",16)+GetNumeric("S",19)
  1059. Dim cWGesAbzSV as CellType = CreateCellEx (cWVerschAbzSV,330,0,CELL_TYPE_DYNVERT,FormatAmt(GesAbzSV)+" "+StrStr("S",122),
  1060.     hNormalAbz,CELL_TEXT_RIGHT,COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hNullPen, hNullPen, 5, 10, 15, 0)    
  1061.  
  1062. SetCellBorder(cWGesAbzSV,CELL_BORDER_LEFT,3,PEN_SOLID,COLOR_BLACK)
  1063.     
  1064.     
  1065. Dim cWVerschAbzSVEZ as CellType = CreateCell (1850,0,CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  1066. SetCellParent (cWVerschAbzSVEZ,cAbzuegeSV)
  1067. SetCellBorder(cWVerschAbzSVEZ,CELL_BORDER_TOP,0,PEN_NULL,COLOR_BLACK)
  1068. Dim cWSVBruttoEZ as CellType = CreateCellEx (cWVerschAbzSVEZ,cSVBruttoW,0,CELL_TYPE_DYNVERT,"",hNormalAbz,CELL_TEXT_RIGHT,
  1069.     COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 10)
  1070. Dim cWZVKBruttoEZ as CellType = CreateCellEx (cWVerschAbzSVEZ,cZVKBruttoW,0,CELL_TYPE_DYNVERT,"",hNormalAbz,CELL_TEXT_RIGHT,
  1071.     COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen,5, 10, 15, 10)
  1072. Dim cWAbzKVEZ as CellType = CreateCellEx (cWVerschAbzSVEZ,cAbzKVW,0,CELL_TYPE_DYNVERT,"",hNormalAbz,CELL_TEXT_RIGHT,
  1073.     COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 10)
  1074. Dim cWAbzPVEZ as CellType = CreateCellEx (cWVerschAbzSVEZ,cAbzPVW,0,CELL_TYPE_DYNVERT,"",hNormalAbz,CELL_TEXT_RIGHT,
  1075.     COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 0)
  1076. Dim cWAbzRVEZ as CellType = CreateCellEx (cWVerschAbzSVEZ,cAbzRVW,0,CELL_TYPE_DYNVERT,"",hNormalAbz,CELL_TEXT_RIGHT,
  1077.     COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 10)
  1078. Dim cWAbzAVEZ as CellType = CreateCellEx (cWVerschAbzSVEZ,cAbzAVW,0,CELL_TYPE_DYNVERT,"",hNormalAbz,CELL_TEXT_RIGHT,
  1079.     COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 10)
  1080. Dim GesAbzSVEZ as Numeric
  1081. GesAbzSVEZ=GetNumeric("S",14)+GetNumeric("S",29)+GetNumeric("S",17)+GetNumeric("S",20)
  1082. Dim cWGesAbzSVEZ as CellType = CreateCellEx (cWVerschAbzSVEZ,330,0,CELL_TYPE_DYNVERT,"",
  1083.     hNormalAbz,CELL_TEXT_RIGHT,COLOR_WHITE, hSolidPen, hNullPen, hSolidPen, hSolidPen, hNullPen, 5, 10, 15, 10)
  1084. 'Fⁿr den Fall, da▀ die MΣrzklausel zum Tragen kommt
  1085. If is("E",1) then 
  1086.             SetCellText(cWSVBruttoEZ, StrAmt("S",5)+" "+StrStr("S",123))
  1087.             SetCellText(cWAbzKVEZ, StrAmt("S",14)+" "+StrStr("S",123))
  1088.             SetCellText(cWAbzPVEZ, StrAmt("S",29)+" "+StrStr("S",123))
  1089.             SetCellText(cWAbzRVEZ, StrAmt("S",17)+" "+StrStr("S",123))
  1090.             SetCellText(cWAbzAVEZ, StrAmt("S",20)+" "+StrStr("S",123))
  1091.             SetCellText(cWGesAbzSVEZ,FormatAmt(GesAbzSVEZ)+" "+StrStr("S",123))
  1092. End If
  1093. SetCellBorder(cWGesAbzSVEZ,CELL_BORDER_LEFT,3,PEN_SOLID,COLOR_BLACK)
  1094.  
  1095.  
  1096. 'Ende Aufschlⁿsselung
  1097.  
  1098. 'Gesamte gesetzliche Abzⁿge und Netto-Verdienst
  1099. Dim cGNettoVerd as CellType = CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  1100. BorderWidth(cGNettoVerd,3,0,3,0)
  1101. SetCellTextBorder(cGNettoVerd,0,0,0,0)
  1102. 'Dim cGesGesAbz as CellType = CreateCellEx (cGNettoVerd,330,0,CELL_TYPE_DYNVERT,"Ges-gesetzl. Abzⁿge",hNormal2,CELL_TEXT_RIGHT,
  1103. '    COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 0, 5, 5, 5)
  1104. 'Dim cWGesGesAbz as CellType = CreateCellEx (cGNettoVerd,330,0,CELL_TYPE_DYNVERT,StrAmt("S",24)+" "+StrStr("S",124),
  1105. '    hBold,CELL_TEXT_RIGHT,COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 0, 20, 20, 20)
  1106. Dim cNettoVerd as CellType = CreateCellEx (cGNettoVerd,330,45,CELL_TYPE_DYNVERT,"Netto-Verdienst",hNormal2,CELL_TEXT_RIGHT,
  1107.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  1108. Dim cWGNettoVerd as CellType = CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  1109. BorderWidth(cWGNettoVerd,3,0,3,0)
  1110. Dim cWNettoVerd as CellType = CreateCellEx (cWGNettoVerd,330,0,CELL_TYPE_DYNVERT,MinusAbsetzen(GetNumeric("R",3))+" "+StrStr("R",103),hBold,CELL_TEXT_RIGHT,
  1111.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 0, 10, 15, 5)
  1112.  
  1113.  
  1114. 'Netto-Bezⁿge/-Abzⁿge mit Aufschlⁿsselung
  1115. Dim cNetto as CellType = CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT + CELL_TYPE_VERT)
  1116. BorderWidth(cNetto,3,3,3,3)
  1117. Dim cNettoBABet as CellType = CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  1118. SetCellParent(cNettoBABet,cNetto)
  1119. SetCellTextBorder(cNettoBABet,0,0,0,0)
  1120. '▄berschriften
  1121. Dim cNettoBA as CellType = CreateCellEx (cNettoBABet,1520,0,CELL_TYPE_DYNVERT,"Netto-Bezⁿge / -Abzⁿge",hBold,CELL_TEXT_LEFT,
  1122.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 15, 7, 5, 0)
  1123. Dim cNettoBet as CellType = CreateCellEx (cNettoBABet,330,0,CELL_TYPE_DYNVERT,"",hNormal2,CELL_TEXT_RIGHT,
  1124.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  1125.  
  1126. 'Aufschlⁿsselung
  1127. 'Zellendefinierung
  1128. Dim cNAufschl as CellType = CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  1129. SetCellParent(cNAufschl,cNetto)
  1130. Dim cNAufschlN as CellType = CreateCell (1520,717,CELL_TYPE_DYNVERT + CELL_TYPE_VERT)
  1131. SetCellParent(cNAufschlN,cNAufschl)
  1132. Dim cNAufschlW as CellType = CreateCell (330,717,CELL_TYPE_DYNVERT + CELL_TYPE_VERT)
  1133. SetCellParent(cNAufschlW,cNAufschl)
  1134.  
  1135. Dim cPauschAbzug as CellType
  1136. Dim cWPauschAbzug as CellType
  1137. Dim cNettoLZ as CellType
  1138. Dim cWNettoLZ as CellType
  1139.  
  1140. Dim ctNettoLohnart as celltemplateType
  1141. dim ctNettoBetrag as celltemplateType
  1142. dim ctNettoBetragW as celltemplateType
  1143.  
  1144. ctNettoLohnart=createCellTemplate(1190,0,CELL_TYPE_DYNVERT,hNormalB,CELL_TEXT_LEFT,
  1145.     COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen,15, 3, 0, 0)
  1146.  
  1147. ctNettoBetrag=createCellTemplate(250,0,CELL_TYPE_DYNVERT,hNormalB,CELL_TEXT_RIGHT,
  1148.     COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen,5, 3, 0, 0)
  1149.  
  1150. ctNettoBetragW=createCellTemplate (80,0,CELL_TYPE_DYNVERT,hNormalB,CELL_TEXT_LEFT,
  1151.     COLOR_WHITE, hNullPen, hNullPen, hSolidPen, hNullPen, hNullPen,0, 3, 5, 0)
  1152.  
  1153. Dim q as Numeric    
  1154. Dim r as Numeric=1
  1155.  
  1156. function EinfgNettoBetrag(Lohnart as String, s as String, n as Numeric)    
  1157.     
  1158.     CreateCellEx(cNAufschlN,1520,0,CELL_TYPE_DYNVERT+CELL_TYPE_HORZ,"",hNormalB,CELL_TEXT_LEFT,
  1159.         COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen,0, 0, 0, 0)
  1160.     
  1161.     CreateCellEx(cNAufschlW, 330,0,CELL_TYPE_DYNVERT+CELL_TYPE_HORZ,"",hNormalB,CELL_TEXT_LEFT,
  1162.         COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen,0, 0, 0, 0)
  1163.  
  1164.     q=q+1
  1165.     SetCellTextBorder(Cell(cNAufschlN,q),0,0,0,0)
  1166.     SetCellTextBorder(Cell(cNAufschlW,q),0,0,0,0)
  1167.     SetCellBorder(Cell(cNAufschlN,q),CELL_BORDER_ALL,0,PEN_NULL,COLOR_TRANSPARENT)
  1168.     SetCellBorder(Cell(cNAufschlW,q),CELL_BORDER_ALL,0,PEN_NULL,COLOR_TRANSPARENT)
  1169.  
  1170.     Dim stNettoBetrag as String
  1171.     Dim stNettoWaehrung as String
  1172.     Dim NumNettoBetrag as Numeric
  1173.     
  1174.     NumNettoBetrag=GetNumeric(s,n)
  1175.     stNettoWaehrung=StrStr(s,100+n)
  1176.     If stWaehrFirma<>stNettoWaehrung Then    
  1177.         If stNettoWaehrung="DM" Then
  1178.             stKorrBetrag=KorrDMnachEUR(NumNettoBetrag)
  1179.             stKorrWaehrung=" EUR"
  1180.         Else
  1181.             stKorrBetrag=KorrEURnachDM(NumNettoBetrag)
  1182.             stKorrWaehrung=" DM"
  1183.         End If
  1184.     Else
  1185.         stKorrBetrag=""
  1186.         stKorrWaehrung=""
  1187.     End If
  1188.  
  1189.     If (blOutputFirma=FALSE) AND (stKorrWaehrung<>"") Then
  1190.         createCellFromTemplate(ctNettoLohnart,Cell(cNAufschlN,q),Lohnart)
  1191.         createCellFromTemplate(ctNettoBetrag,Cell(cNAufschlN,q),FormatAmt(NumNettoBetrag))
  1192.         createCellFromTemplate(ctNettoBetragW,Cell(cNAufschlN,q)," "+stNettoWaehrung)
  1193.         createCellFromTemplate(ctNettoBetrag,Cell(cNAufschlW,q),stKorrBetrag)
  1194.         createCellFromTemplate(ctNettoBetragW,Cell(cNAufschlW,q),stKorrWaehrung)
  1195.     Else
  1196.         createCellFromTemplate(ctNettoLohnart,Cell(cNAufschlN,q),Lohnart)    
  1197.         createCellFromTemplate(ctNettoBetrag,Cell(cNAufschlN,q),stKorrBetrag)
  1198.         createCellFromTemplate(ctNettoBetragW,Cell(cNAufschlN,q),stKorrWaehrung)
  1199.         createCellFromTemplate(ctNettoBetrag,Cell(cNAufschlW,q),FormatAmt(NumNettoBetrag))
  1200.         createCellFromTemplate(ctNettoBetragW,Cell(cNAufschlW,q)," "+stNettoWaehrung)
  1201.     End If
  1202. end function
  1203.  
  1204.  
  1205. Dim Nettobezug as Numeric=0
  1206.  
  1207. 'Auswahl der anzuzeigenden Be-/Abzⁿge
  1208.  
  1209. 'Verm÷genswirksame Leistungen
  1210. If is("D",26) then
  1211.     EinfgNettoBetrag("Verm÷genswirksame Leistungen","A",31)
  1212. End If
  1213.  
  1214. 'Dienstwagen
  1215. If is("D",20) then
  1216.     EinfgNettoBetrag("Dienstwagen","A",30)
  1217. End If
  1218.  
  1219. 'Direktversicherung
  1220. If is("D",21) then
  1221.     If is("D",79) then
  1222.         stLohnart="Direktvers.: -"+FormatAmt(GetNumeric("A",51)-GetNumeric("A",46))+"; pausch.LSt: "+StrAmt("A",43)+"; pausch.SolZ: "+StrAmt("A",44)+"; pausch.KiSt: "+StrAmt("A",45)
  1223.     Else
  1224.         stLohnart="Direktversicherung"
  1225. End If
  1226. EinfgNettoBetrag(stLohnart,"A",33)
  1227. End If
  1228.  
  1229. '1.-3. Steuerfreier Abzug
  1230. While r<=3 Do
  1231.     If is("D",26+r) then
  1232.         stLohnart=StrStr("D",35+r)
  1233.         If stLohnart="" Then stLohnart="Steuerfreier Abzug "+FormatNumeric("%0.0f",r) End If
  1234.         EinfgNettoBetrag(stLohnart,"A",34+r)
  1235.     End If
  1236.     r=r+1
  1237. End While
  1238.  
  1239. r=1
  1240.  
  1241. '1.-3. Geldwerter Vorteil
  1242. While r<=3 Do
  1243.     If is("D",22+r) then
  1244.         stLohnart=StrStr("D",32+r)
  1245.         If stLohnart="" Then stLohnart="Geldwerter Vorteil "+FormatNumeric("%0.0f",r) End If
  1246.         EinfgNettoBetrag(stLohnart,"A",37+r)
  1247.     End If
  1248.     r=r+1
  1249. End While
  1250.  
  1251. 'Fahrtgeld
  1252. Dim FahrgeldSchluessel as Numeric
  1253. If is("D",50) then
  1254.     FahrgeldSchluessel=GetInt("D",51)
  1255.     If FahrgeldSchluessel=2 Then stLohnart="Fahrgeld steuerfrei"
  1256.     Else If FahrgeldSchluessel=3 Then stLohnart="Pauschalsteuer Fahrgeld" End If
  1257.     End If
  1258.     EinfgNettoBetrag(stLohnart,"B",15)
  1259. End If
  1260.  
  1261. r=1
  1262.  
  1263. '1.-3. Steuerfreier Bezug
  1264. While r<=3 Do
  1265.     If is("D",29+r) then
  1266.         stLohnart=StrStr("D",38+r)
  1267.         If stLohnart="" Then stLohnart="Steuerfreier Bezug "+FormatNumeric("%0.0f",r) End If
  1268.         EinfgNettoBetrag(stLohnart,"B",4+r)
  1269.     End If
  1270.     r=r+1
  1271. End While
  1272.  
  1273. 'Kindergeld
  1274. If is("D",77) then
  1275.     EinfgNettoBetrag("Kindergeld","B",14)
  1276. End If
  1277.  
  1278. 'Pauschal versteuertes Fahrgeld
  1279. If is("D",52) then
  1280.     EinfgNettoBetrag("Fahrgeld pauschal versteuert durch AG","A",42)
  1281. End If
  1282.  
  1283. 'wenn Arbeitnehmer nicht in der gesetzlichen Krankenversicherung
  1284. If GetInt("D",7)=9 then
  1285.     EinfgNettoBetrag("Abzug Freiw. KV","A",32)
  1286.     EinfgNettoBetrag("AG-Ant. Freiw. KV","B",3)
  1287. End If
  1288.  
  1289. 'wenn Arbeitnehmer nicht in der Pflegeversicherung
  1290. If GetInt("D",10)=9 then
  1291.     EinfgNettoBetrag("Abzug Freiw. PV","A",41)
  1292.     EinfgNettoBetrag("AG-Ant. Freiw. PV","B",13)
  1293. End If
  1294.  
  1295. 'Kammerbeitrag
  1296. If is("D",18) then
  1297.     EinfgNettoBetrag("Kammerbeitrag","A",34)
  1298. End If
  1299.  
  1300. 'ZVK-Umlage
  1301. If OeffentlDienstBetrag=1 then EinfgNettoBetrag("VBL/ZVK-Arbeitnehmer-Umlage","A",47) End If
  1302. If OeffentlDienstBetrag=2 then EinfgNettoBetrag("VBLU-Arbeitnehmer-Umlage","A",47) End If
  1303.  
  1304. 'VBL/ZVK-Erh÷hungsbetrag
  1305. If Is("R",27) Then EinfgNettoBetrag("VBL/ZVK-Erh÷hungsbetrag","A",52) End If
  1306.  
  1307. If 0<q Then
  1308.     SetCellTextBorder(Cell(Cell(cNAufschlN,1),1),15, 10, 0, 0)
  1309.     SetCellTextBorder(Cell(Cell(cNAufschlN,1),2),5, 10, 0, 0)
  1310.     SetCellTextBorder(Cell(Cell(cNAufschlN,1),3),0, 10, 5, 0)
  1311.     SetCellTextBorder(Cell(Cell(cNAufschlW,1),1),5, 10, 0, 0)
  1312.     SetCellTextBorder(Cell(Cell(cNAufschlW,1),2),0, 10, 5, 0)
  1313. End If
  1314.  
  1315.  
  1316. function EinfgNettoBetragAlt(LohnartWert as CellType, Betrag as String, Waehrung as String)    
  1317.     createCellFromTemplate(ctNettoBetrag,LohnartWert,Betrag ) 
  1318.     createCellFromTemplate(ctNettoBetragW,LohnartWert," "+Waehrung )
  1319. end function
  1320.  
  1321.  
  1322. 'Pauschale Abzⁿge
  1323. Dim PauschAbzWert as String
  1324. PauschAbzWert=FormatAmt(GetNumeric("A",48)+GetNumeric("A",49)+GetNumeric("A",50))
  1325. If (SteuerklasseBetrag=-2) AND (PauschAbzWert<>"0,00") Then
  1326.     cPauschAbzug=CreateCellEx (cNAufschlN,1520,0,CELL_TYPE_DYNVERT,"Pauschale Abzⁿge",hNormalN,CELL_TEXT_LEFT,
  1327.         COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen, 15, 10, 5, 0)
  1328.     cWPauschAbzug=CreateCellEx (cNAufschlW,330,0,CELL_TYPE_DYNVERT+CELL_TYPE_HORZ,"",hNormalN,CELL_TEXT_RIGHT,
  1329.         COLOR_WHITE, hNullPen, hNullPen, hNullPen, hNullPen, hNullPen, 0, 0, 0, 0)
  1330.     EinfgNettoBetragAlt(cWPauschAbzug,PauschAbzWert,StrStr("A",150))
  1331. End If
  1332.  
  1333. cNettoLZ = CreateCellEx (cNAufschlN,1520,10,CELL_TYPE_DYNHORZ,"",hNormalB,CELL_TEXT_LEFT,
  1334.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 15, 0, 5, 0)
  1335. SetCellBorder(cNettoLZ,CELL_BORDER_TOP,0,PEN_SOLID,COLOR_WHITE)
  1336. SetCellBorder(cNettoLZ,CELL_BORDER_BOTTOM,0,PEN_SOLID,COLOR_WHITE)
  1337. cWNettoLZ = CreateCellEx (cNAufschlW,330,10,CELL_TYPE_DYNHORZ,"",hNormalB,CELL_TEXT_RIGHT,
  1338.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 0, 15, 0)
  1339. SetCellBorder(cWNettoLZ,CELL_BORDER_TOP,0,PEN_SOLID,COLOR_WHITE)
  1340. SetCellBorder(cWNettoLZ,CELL_BORDER_BOTTOM,0,PEN_SOLID,COLOR_WHITE)
  1341.  
  1342.  
  1343. 'Ende Aufschlⁿsselung
  1344.  
  1345. 'Gesamte Netto-Be-/Abzⁿge
  1346. Dim cNettoBeAb as CellType = CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  1347. SetCellTextBorder(cNettoBeAb,0,0,0,0)
  1348. Dim cNBezAbz as CellType = CreateCellEx (cNettoBeAb,330,45,CELL_TYPE_DYNVERT,"Netto-Bezⁿge/ -Abzⁿge",hNormal2,CELL_TEXT_RIGHT,
  1349.     COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 5, 7, 15, 0)
  1350. BorderWidth(cNettoBeAb,3,0,3,0)
  1351. Dim cWNettoBeAb as CellType = CreateCell (0,0,CELL_TYPE_DYNHORZ + CELL_TYPE_DYNVERT + CELL_TYPE_HORZ)
  1352. BorderWidth(cWNettoBeAb,3,0,3,0)
  1353. Dim cWNBezAbz as CellType = CreateCellEx (cWNettoBeAb,330,0,CELL_TYPE_DYNVERT,MinusAbsetzen(GetNumeric("R",11))+" "+StrStr("R",111),
  1354.     hBold,CELL_TEXT_RIGHT,COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 0, 10, 15, 5)
  1355.  
  1356.  
  1357. 'endgⁿltige Auszahlung
  1358.  
  1359. Dim cZahlg as CellType=CreateCell(0,0,CELL_TYPE_DYNHORZ+CELL_TYPE_DYNVERT+CELL_TYPE_HORZ)
  1360. BorderWidth(cZahlg,3,3,3,3)
  1361. SetCellTextBorder(cZahlg,0,0,0,0)
  1362.  
  1363. Dim cZahlgWie as CellType=CreateCell(nBreite_cZahlgWie,0,CELL_TYPE_DYNVERT+CELL_TYPE_VERT)
  1364. SetCellParent(cZahlgWie, cZahlg)
  1365. SetCellTextBorder(cZahlgWie,0,0,0,0)
  1366. Dim cZahlgKorrWaehr as CellType = CreateCell (nBreite_cZahlgKorrWaehr,0,CELL_TYPE_DYNVERT+CELL_TYPE_VERT) 
  1367. SetCellParent(cZahlgKorrWaehr, cZahlg)
  1368. SetCellTextBorder(cZahlgKorrWaehr,0,0,0,0)
  1369. Dim cZahlgWaehr as CellType = CreateCell (0,0,CELL_TYPE_DYNHORZ+CELL_TYPE_DYNVERT+CELL_TYPE_VERT)
  1370. SetCellParent(cZahlgWaehr, cZahlg)
  1371. SetCellTextBorder(cZahlgWaehr,0,0,0,0)
  1372.  
  1373. Dim Zahlart as String
  1374. 'If Is("P",60) Then ZahlArt="Auszahlung erfolgte bar" End If
  1375. If Is("P",60) Then ZahlArt="Auszahlungsbetrag dankend erhalten" End If
  1376. If Is("P",61) Then ZahlArt="Auszahlung durch Scheck" End If            
  1377. If Is("P",62) Then ZahlArt="Auszahlung durch ▄berweisung" End If
  1378.  
  1379. Dim cZahlArt as CellType=CreateCellEx (cZahlgWie,nBreite_cZahlgWie,45,CELL_TYPE_DYNVERT,ZahlArt,
  1380.     hBold,CELL_TEXT_LEFT,COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 15, 7, 15, 0)
  1381.  
  1382. Dim BankVerb as String
  1383.  
  1384. If Is("P",62) Then
  1385.     BankVerb="Bank: " + StrStr("P",25) + ", Konto-Nr.: " + StrStr("P",26) + ", BLZ:  " + StrInt("P",24)
  1386. End IF
  1387.  
  1388.  
  1389. Dim cBankVerb as CellType=CreateCellEx (cZahlgWie,nBreite_cZahlgWie,75,CELL_TYPE_DYNVERT,BankVerb,
  1390.     hNormalB,CELL_TEXT_LEFT,COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 15, 23, 5, 20)
  1391.  
  1392. If Is("P",60) Then
  1393.  
  1394.     SelectCellFont(cBankVerb,hNormalB)
  1395.     SetCellText(cBankVerb,"Datum, Unterschrift")
  1396.     
  1397. End If    
  1398.  
  1399.  
  1400.  
  1401. Dim cAuszKorrWaehr as CellType =CreateCellEx (cZahlgKorrWaehr,nBreite_cZahlgKorrWaehr,45,CELL_TYPE_DYNHORZ,"Auszahlung in "+ StrStr("R",125),
  1402.     hNormalB,CELL_TEXT_RIGHT,COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 15, 7, 15, 0) 
  1403. Dim cWAuszKorrWaehr as CellType = CreateCellEx (cZahlgKorrWaehr,nBreite_cZahlgKorrWaehr,75,CELL_TYPE_DYNHORZ,MinusAbsetzen(GetNumeric("R",25))+" "+StrStr("R",125),ExtraBold,
  1404.     CELL_TEXT_RIGHT, COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 0, 20, 15, 20)
  1405.  
  1406. Dim cAuszWaehr as CellType =CreateCellEx (cZahlgWaehr,330,45,CELL_TYPE_DYNHORZ,"Auszahlung in "+ StrStr("R",105),
  1407.     hNormalB,CELL_TEXT_RIGHT,COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 15, 7, 15, 0) 
  1408. Dim cWAuszWaehr as CellType = CreateCellEx (cZahlgWaehr,330,75,CELL_TYPE_DYNHORZ,MinusAbsetzen(GetNumeric("R",5))+" "+StrStr("R",105),ExtraBold,
  1409.     CELL_TEXT_RIGHT, COLOR_WHITE, hSolidPen, hSolidPen, hSolidPen, hSolidPen, hNullPen, 0, 20, 15, 20)
  1410.  
  1411.  
  1412.  
  1413.  
  1414.  
  1415. 'Ausdruck des Tabellenkopfes
  1416.  
  1417. DrawCell(cKopfTop,TRUE)
  1418. SetPos(940,GetPosY())
  1419. DrawCell(cKopfRechts,TRUE)
  1420.  
  1421.  
  1422.  
  1423. 'Adresse
  1424.  
  1425.  
  1426. 'Bankangaben
  1427.  
  1428. SetPos(0,GetPosY())
  1429. RemoveAllTabs()
  1430. SetTabs("L0")
  1431. 'TL("\tBank :  " + StrStr("P",25) + "         Konto-Nr. :  " + StrStr("P",26) + "         BLZ :  " + StrInt("P",24))
  1432. 'TL("\tKonto-Nr.:  " + StrStr("P",26))
  1433. 'TL("\tBLZ:  " + StrInt("P",24))
  1434.  
  1435. 'eigentliche Tabelle
  1436. SetPos(0,590)
  1437. DrawCell (cBrutto, TRUE)
  1438. SetPos(0,GetPosY())
  1439. DrawCell (cStSVGBrutto,TRUE)
  1440. 'DrawCell (cGBrutto,TRUE)
  1441. 'DrawCell (cWGBrutto,TRUE)
  1442. SetPos(0,GetPosY())
  1443. DrawCell (cAbzuegeSt,TRUE)
  1444. SetPos(0,GetPosY())
  1445. DrawCell (cAbzuegeSV,TRUE)
  1446. SetPos(1520,GetPosY())
  1447. DrawCell (cGNettoVerd,TRUE)
  1448. DrawCell (cWGNettoVerd,TRUE)
  1449. SetPos(0,GetPosY())
  1450. DrawCell (cNetto,TRUE)
  1451. SetPos(1520,GetPosY())
  1452. DrawCell (cNettoBeAb,TRUE)
  1453. DrawCell (cWNettoBeAb,TRUE)
  1454. SetPos(0,GetPosY())
  1455. DrawCell (cZahlg,TRUE)
  1456. 'SetPos(0,GetPosY())
  1457. 'DrawCell (cWAuszahlung,TRUE)
  1458.  
  1459. 'SetPos(0, GetPosY()-90)
  1460. 'SetFont("Arial",8,FONT_NORMAL,COLOR_BLACK)
  1461. 'Zahlungsart
  1462. 'If is("P",60) then TL("Auszahlung erfolgte bar") End If
  1463. 'If is("P",61) then TL("Auszahlung erfolgte per Scheck") End If            
  1464. 'If is("P",62) then TL("Auszahlung erfolgte durch ▄berweisung") End If
  1465. 'SetPos(0,GetPosY()+10)
  1466. 'T("\tBank :  " + StrStr("P",25) + "         Konto-Nr. :  " + StrStr("P",26) + "         BLZ :  " + StrInt("P",24))
  1467.  
  1468. '    SetPos(0,2410)
  1469. '    DrawCell(cGrafik,true)
  1470.  
  1471.  
  1472.  
  1473. SetPos(20,GetPosY()+10)
  1474. SetFont("Arial",8,FONT_NORMAL,COLOR_BLACK)
  1475. T("Lexware lohnauskunft "+GetProgramVersion())
  1476. SetTabs("R-20")
  1477. T("\t"+FormatDate("%d.%m.%Y",Now()))
  1478. RemoveAllTabs()
  1479.