Thema: Delphi Befehl kürzen

Einzelnen Beitrag anzeigen

Benutzerbild von R34DM3
R34DM3

Registriert seit: 6. Feb 2008
10 Beiträge
 
#1

Befehl kürzen

  Alt 10. Feb 2008, 20:23
moin zusammen,

kennt jemand ne möglichkeit diesen code:

Delphi-Quellcode:
     if (gb19.Caption = Fahrzeug1.fkennung) and ((btbg19.Caption <> '4') or (falscherstatus = false) or (btbg19.Caption <> '6') or (btbg19.Caption <> '7') or (btbg19.Caption <> '8') or (btbg19.Caption <> '3') ) then btbg19.Caption := '3else if (gb20.Caption = Fahrzeug4.fkennung) and (btbg19.Caption = '1') or (btbg19.Caption = '2') or (btbg19.Caption = '5') then falscherstatus := true;
     if (gb19.Caption = Fahrzeug2.fkennung) and ((btbg19.Caption <> '4') or (falscherstatus = false) or (btbg19.Caption <> '6') or (btbg19.Caption <> '7') or (btbg19.Caption <> '8') or (btbg19.Caption <> '3') ) then btbg19.Caption := '3else if (gb20.Caption = Fahrzeug4.fkennung) and (btbg19.Caption = '1') or (btbg19.Caption = '2') or (btbg19.Caption = '5') then falscherstatus := true;
     if (gb19.Caption = Fahrzeug3.fkennung) and ((btbg19.Caption <> '4') or (falscherstatus = false) or (btbg19.Caption <> '6') or (btbg19.Caption <> '7') or (btbg19.Caption <> '8') or (btbg19.Caption <> '3') ) then btbg19.Caption := '3else if (gb20.Caption = Fahrzeug4.fkennung) and (btbg19.Caption = '1') or (btbg19.Caption = '2') or (btbg19.Caption = '5') then falscherstatus := true;
     if (gb19.Caption = Fahrzeug4.fkennung) and ((btbg19.Caption <> '4') or (falscherstatus = false) or (btbg19.Caption <> '6') or (btbg19.Caption <> '7') or (btbg19.Caption <> '8') or (btbg19.Caption <> '3') ) then btbg19.Caption := '3else if (gb20.Caption = Fahrzeug4.fkennung) and (btbg19.Caption = '1') or (btbg19.Caption = '2') or (btbg19.Caption = '5') then falscherstatus := true;

     if (gb20.Caption = Fahrzeug1.fkennung) and ((btbg20.Caption <> '4') or (falscherstatus = false) or (btbg20.Caption <> '6') or (btbg20.Caption <> '7') or (btbg20.Caption <> '8') or (btbg20.Caption <> '3') ) then btbg20.Caption := '3else if (gb20.Caption = Fahrzeug4.fkennung) and (btbg20.Caption = '1') or (btbg20.Caption = '2') or (btbg20.Caption = '5') then falscherstatus := true;
     if (gb20.Caption = Fahrzeug2.fkennung) and ((btbg20.Caption <> '4') or (falscherstatus = false) or (btbg20.Caption <> '6') or (btbg20.Caption <> '7') or (btbg20.Caption <> '8') or (btbg20.Caption <> '3') ) then btbg20.Caption := '3else if (gb20.Caption = Fahrzeug4.fkennung) and (btbg20.Caption = '1') or (btbg20.Caption = '2') or (btbg20.Caption = '5') then falscherstatus := true;
     if (gb20.Caption = Fahrzeug3.fkennung) and ((btbg20.Caption <> '4') or (falscherstatus = false) or (btbg20.Caption <> '6') or (btbg20.Caption <> '7') or (btbg20.Caption <> '8') or (btbg20.Caption <> '3') ) then btbg20.Caption := '3else if (gb20.Caption = Fahrzeug4.fkennung) and (btbg20.Caption = '1') or (btbg20.Caption = '2') or (btbg20.Caption = '5') then falscherstatus := true;
     if (gb20.Caption = Fahrzeug4.fkennung) and ((btbg20.Caption <> '4') or (falscherstatus = false) or (btbg20.Caption <> '6') or (btbg20.Caption <> '7') or (btbg20.Caption <> '8') or (btbg20.Caption <> '3') ) then btbg20.Caption := '3else if (gb20.Caption = Fahrzeug4.fkennung) and (btbg20.Caption = '1') or (btbg20.Caption = '2') or (btbg20.Caption = '5') then falscherstatus := true;
is eine procedure oder sowas zu stecken um ihn kürzer zu machen?! ^^

schonmal danke im vorraus
mfg markus
blub
  Mit Zitat antworten Zitat