if then else with multiple assignments
Hi,
I want to use this code:
begin
if (<AuftragsKopf."KENNZ1"> = 'WfE') then
Set( 'variable1','''text1''');
Set( 'variable2','''text2''');
Set( 'variable3',''''+<Bearbeiter."PersAnrede">+'''' );
Set( 'variable4','''text3''' );
Set( 'variable5','''40''' );
pictureBasisKopfLogo.Visible := False;
pictureBasisKopfLogoWfE.Visible := True;
else
Set( 'variable1','''text10''');
Set( 'variable2','''text20''');
Set( 'variable3',''''+<Bearbeiter."PersAnrede">+'''' );
Set( 'variable4','''text30''' );
Set( 'variable5','''30''' );
pictureBasisKopfLogo.Visible := True;
pictureBasisKopfLogoWfE.Visible := False;
end;
I get everytime the error Message: ';' expected (bevor the "else").
I tried it everywhere with ";" and without.
What can I Do?
I want to use this code:
begin
if (<AuftragsKopf."KENNZ1"> = 'WfE') then
Set( 'variable1','''text1''');
Set( 'variable2','''text2''');
Set( 'variable3',''''+<Bearbeiter."PersAnrede">+'''' );
Set( 'variable4','''text3''' );
Set( 'variable5','''40''' );
pictureBasisKopfLogo.Visible := False;
pictureBasisKopfLogoWfE.Visible := True;
else
Set( 'variable1','''text10''');
Set( 'variable2','''text20''');
Set( 'variable3',''''+<Bearbeiter."PersAnrede">+'''' );
Set( 'variable4','''text30''' );
Set( 'variable5','''30''' );
pictureBasisKopfLogo.Visible := True;
pictureBasisKopfLogoWfE.Visible := False;
end;
I get everytime the error Message: ';' expected (bevor the "else").
I tried it everywhere with ";" and without.
What can I Do?
Comments
IF (1=1) THEN
BEGIN
abc:=5;
END
ELSE
BEGIN
abc:=9;
END;