for i:=0 to Notatnik.ComponentCount-1 do
begin
if Notatnik.Components[i] is TMenuItem then
begin
if (Notatnik.Components[i] as TMenuItem).Caption'-' then (Notatnik.Components[i] as TMenuItem).Caption:=INI2.ReadString('menu',Notatnik.Components[i].Name, 'Error Loading Language '+lng);
end;
if Notatnik.Components[i] is TSpeedbutton then
begin
Notatnik.Components[i] as TSpeedbutton).Hint:=INI2.ReadString('toolbar',Notatnik.Components[i].Name, 'Error Loading Language '+lng);
end;
end;
INI2.Free;
end;
Dlaczego w zaznaczonym przeze mnie miejscu wyskakuje:
<font color="red">[Error] NSP.pas(135): Statement expected, but expression of type 'TSpeedButton' found</span>