Paradox DB Short field = WHAT in delphi? 
Author Message
 Paradox DB Short field = WHAT in delphi?

I'm just trying to obtain a simple field value from a Paradox DB. The field is defined
as a SHORT. (this is a primary key field where its value will not exceed 32000). Now, I
wanted to obtain its value in a variable. But how?  I know I'm missing something
obvious.

n: integer;
nn: shortint;

n:= table1Field1.value; {error}
nn:=table1field1.value; {error too}

also won't work
n or nn := table1.field[0].asinteger ;



Fri, 11 Dec 1998 03:00:00 GMT  
 Paradox DB Short field = WHAT in delphi?

Quote:

> I'm just trying to obtain a simple field value from a Paradox DB. The field is defined
> as a SHORT. (this is a primary key field where its value will not exceed 32000). Now, I
> wanted to obtain its value in a variable. But how?  I know I'm missing something
> obvious.

> n: integer;
> nn: shortint;

> n:= table1Field1.value; {error}
> nn:=table1field1.value; {error too}

> also won't work
> n or nn := table1.field[0].asinteger ;

Use n:= table1Field1.AsInteger;
and it will work just fine.

Atle Hammer



Sun, 13 Dec 1998 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. SQL and Date-Field in Paradox-Db

2. Alpha field in Paradox.db

3. Inserting fields into a paradox DB at runtime

4. Delphi 2 DB Missing Fields?

5. DELPHI accessing Paradox DB on WFW3.11

6. Delphi/Paradox/DB Form Wizard

7. Creating an index file for a Paradox 5.0 db file in Delphi 1.0

8. Paradox db Pack in Delphi 1.0

9. Logging in to Paradox db from Delphi

10. Help!! Updating a DB field through FIELDS[x]

11. DElphi 3 paradox table empty fields Variant Conversion error

12. Formatted memo field paradox 4.5 + delphi 5

 

 
Powered by phpBB® Forum Software