function CheckEmpty(sender: Tobject; tipstr: string): boolean;
begin
  if (sender is Tedit) then
  begin
    if trim((sender as Tedit).Text) = '' then
    begin
      application.MessageBox(pchar(tipstr), 'Tips', MB_YESNO  + MB_ICONINFORMATION);
      result := true;
      exit;
    end;
    result := false;
    exit;
  end;
报错提示:这个TEDIT没有定义或没有声明,我是从别人的代码复制过来的,是一个公共函数单元,这是为什么呀!请教高手!