procedure TForm1.MOM;
begin
if label2.caption:='' then
label2.caption:='出现错误。'
else
end;[Error] Unit1.pas(1762): Type of expression must be BOOLEAN
[Fatal Error] Project2.dpr(5): Could not compile used unit 'Unit1.pas'
begin
if label2.caption:='' then
label2.caption:='出现错误。'
else
end;[Error] Unit1.pas(1762): Type of expression must be BOOLEAN
[Fatal Error] Project2.dpr(5): Could not compile used unit 'Unit1.pas'
begin
if label2.caption = '' then //:= 这样是赋值
label2.caption:='出现错误。'
else
end;
begin
if label2.caption = '' then
label2.caption:='出现错误。'
else
;
end;