Código Delphi
[-]
unit Rutinas;
const
sFileDai='C:\file.INI';
Procedure BloquearEdits (Form :TForm);
implementation
uses frAccesoDatos;
Procedure BloquearEdits (Form :TForm);
Var i :Integer;
Begin
for i := 0 to (Form.ComponentCount - 1) do
begin
if (Form.Components[i]) is TEdit then
TEdit(Form.Components[i]).Enabled := False;
end;
end;
........................
unit FrFormulario;
type
TFrFormulario= class(TForm)
edtTitulo : TEdit;
edtValor : TCurrencyEdit;
lblValor : TsLabel;
implementation
uses FrAccesoDatos, Rutinas;
procedure TFrFormulario.FormCreate(Sender: TObject);
begin
BloquearEdits(TFrFormulario);
end;
....................
E2010 Incompatible types: 'TForm' and 'class of TFrmFormulario'
Al compilar me saca este error de incompatibilidad (algo se me escapa de las manos).
el nombre del formulario es "frmFormulario"
si pongo:
BloquearEdits(frmFormulario);
me dice el siguiente error:
E2003 Undeclared identifier: 'FrmFormulario'