20. Februar 2018 17:55
carchecks.SETCURRENTKEY(carchecks."Belegnr.",carchecks."Zeilennr.");
// Hier sollte eigentlich ein SETFILTER/SETRANGE stehen.
IF NOT ((carchecks."Belegnr." = Rec."Document No.") AND (carchecks."Zeilennr." = Rec."Line No.")) THEN BEGIN
Carcheck.SETRANGE(Carcheck.Kategorie,Carcheck.Kategorie::UVV);
IF Carcheck.FIND('-') THEN
REPEAT
carchecks.FINDLAST;
carchecks.ID := carchecks.ID +1;
carchecks."Belegnr." := "Document No.";
carchecks."Kd-Nr." := "Sell-to Customer No.";
carchecks."Zeilennr." := "Line No.";
carchecks."Zeilennr." := "Line No.";
carchecks.Bezeichnug := Carcheck.Bezeichnung;
carchecks."KFZ-Kennzeichen" := "Customer Car No.";
carchecks."Erstell Datum" := TODAY;
carchecks.Kategorie := carchecks.Kategorie::UVV;
carchecks."Mängel?" := FALSE;
carchecks."Nicht prüfbar" := FALSE;
carchecks.Bemerkung := '';
carchecks.INSERT;
UNTIL Carcheck.NEXT = 0;
END ELSE
carchecks.SETRANGE(carchecks."Belegnr.","Document No.");
21. Februar 2018 02:25
21. Februar 2018 08:59