Autor Beitrag
hibbert
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 1007

WinServer2003, Win XP, Linux
D6 Pers, D05
BeitragVerfasst: Di 10.12.02 18:03 
hallo,
ich möchte gerne für eine if anweisung 2 bedingungen stellen.
mit
ausblenden Quelltext
1:
2:
3:
if label1.caption='1' then
if label2.caption='1' then
aktion;
wird es auf die dauer zu unübersichtlich. geht das vielleicht irgendwie anders? z.b. in dieser form:
ausblenden Quelltext
1:
2:
if label1.caption='1' and label2.caption='1'then
aktion;

denn irgendwie muss das ja wohl gehen.
mfg hibbert

_________________
I kunnen väl svara endast ja eller nej
Om i viljen eller nej
Tante
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 41



BeitragVerfasst: Di 10.12.02 18:10 
Ganz genau. Nur besser, du setzt die Bedingung in Klammern:
ausblenden Quelltext
1:
2:
if (label1.caption='1') and (label2.caption='1')then 
aktion;
Christian S.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 20451
Erhaltene Danke: 2264

Win 10
C# (VS 2019)
BeitragVerfasst: Di 10.12.02 18:24 
@Hibbert: schau Dir doch mal dieses kleine FAQ an, dass ich mal geschrieben habe!

MfG,
Peter

_________________
Zwei Worte werden Dir im Leben viele Türen öffnen - "ziehen" und "drücken".