Lazreport Komplex lazarus / 16-Databases ---------------------------------------------------------------------- mr.mc.mauser · 2010-12-13 22:31 Hello, and sorry for my Bad English I want to make a Report with Lazreport My database is: Struktur: Name|Vorname|Ort|Geschlecht| --------------------------------------- Datas: Wagner|Emil|Dausenau|M Wagner|Frieda|Dausenau|W Wagner|Emil|Bornich|M Maus|Robert|Bornich|M Kurz|Karl-Emil|Bornich|M Itzel|Irma|Bornich|W The Report sould make an Output like this:       Geschelcht M             Ort Dausenau                   1. Emil Wagner             Ort Bornich                   1. Emil Wagner                   2. Robert Maus                   3. Karl-Emil Kurz       Geschelcht W             Ort Dausenau                   1. Frieda Wagner Ort Bornich                   2. Irma Itzel I Have Made this: SQL Query: SELECT * FROM adressen ORDER BY mw,ort Report: 1. Band = Masterdata -> Data Source: frDBDataSet1 2. Band = GroupHeader -> ZQuery1'mw' 2. Band Content = DB-Field ZQuery1'mw' -> Memo ZQuery1'mw' 3. Band = GroupHeader -> ZQuery1'ort' 3. Band Content = DB-Field ZQuery1'mw' -> Memo ZQuery1'ort' 4. Band = GroupHeader -> ZQuery1'name' 4. Band Content = DB-Field ZQuery1'mw' -> Memo ZQuery1'name' This makes a Output like this:       Geschlecht M             Ort Dausenau                   Emil Wagner             Ort Bornich                   Emil Wagner                   Robert Maus                   Karl-Emil Kurz       Geschlecht W             Ort Dausenau                   Frieda Wagner Ort Bornich                   Irma Itzel I Must have the Numbers ! Who can i Made this ?? Greetings Robert I Have made the same Question in a German Forum, but not an real good answer... ---------------------------------------------------------------------- fredycc · 2010-12-13 22:58 You can check samples into: C:\lazarus\components\lazreport\samples\; there are some interesting examples or use variables of the report; [CURRENT#] = Current line. Regards. ---------------------------------------------------------------------- mr.mc.mauser · 2010-12-14 00:06 I have test all the Samples in the Folder but Nothing with my Problem..... I have testet all Variables in Lazreport but: [LINE#] makes 1 and 2 after M and W, expect only 1 and 2 [CURRENT#] makes the Wrong Numbers to ! Greetings Robert ---------------------------------------------------------------------- guidoaerts · 2010-12-14 19:19 I suggest you add a integer-variable to your report, which you set to 1 in the OnBeginBand (of the 4. Band) of the TfrReport. Increment it in the script of the appropriate data-band. Guido