[fpc-pascal] with statement using mulltiple objects

Vojtěch Čihák vojtech.cihak at atlas.cz
Sun Sep 14 16:41:46 CEST 2014


Hi,
 
once I came to troubles with "with":
 
procedure TForm1.StringGrid1SelectEditor(Sender: TObject; aCol, aRow: Integer; var Editor: TWinControl);
begin
  with StringGrid1 do
    begin
      ...
      Editor:= ...;
      ...
    end;
end; 

because Editor is also public property of TStringGrid. Here would be solution to rename parameter to "AEditor".
 
Vojtěch
_______________________________________________
fpc-pascal maillist  -  fpc-pascal at lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal <http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20140914/cf713d2c/attachment.html>


More information about the fpc-pascal mailing list