Foros Club Delphi

Foros Club Delphi (https://www.clubdelphi.com/foros/index.php)
-   Tablas planas (https://www.clubdelphi.com/foros/forumdisplay.php?f=20)
-   -   Saber si existe un campo en una tabla (https://www.clubdelphi.com/foros/showthread.php?t=21773)

Investment 27-05-2005 09:15:54

Saber si existe un campo en una tabla
 
¿Existe alguna forma mejor de saber si existe un campo en una tabla de paradox que la que pongo a continuacion?
Código:

  try
        if TableOrigen.fieldbyname('TIPO_EXPED').asString<>'jkfrfkleivj' then
          ShowMessage('Existe TIPO_EXPED');
  except
          ShowMessage(' N O          E X I S T E        T I P O _ E X P E D');
   end;

Seguro que si, pero no doy con ello.

Gracias de antemano.

marcoszorrilla 27-05-2005 09:39:58

Guten Morgen Peter:

Código Delphi [-]
 procedure TForm1.Button1Click(Sender: TObject);
 begin
 if Table1.FindField('Addr1s') = nil then
 ShowMessage('El no Campo existe.');
 end;
Un Saludo.

Investment 27-05-2005 09:50:02

Buona mattina Marcos.

Muchas gracias por la respuesta y por la rapidez.

Have a nice day ;)


La franja horaria es GMT +2. Ahora son las 10:59:08.

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Traducción al castellano por el equipo de moderadores del Club Delphi