Recent

Author Topic: Load a Dbf Memo field from one table to another table Dbf Memo field  (Read 726 times)

1HuntnMan

  • Full Member
  • ***
  • Posts: 200
  • From Delphi 7 to Lazarus
    • NewFound Photo Art
Usually I load data from one table field to another table field that are either string or integer fields, i.e.
 
Code: Pascal  [Select][+][-]
  1.     DbfAppmts.FieldByName('CNTKFNAME').AsString:=
  2.      DbfCntks.FieldByName('CNTKFNAME').AsString;
  3.     DbfAppmts.FieldByName('CNTKMI').AsString:=
  4.      DbfCntks.FieldByName('CNTKMI').AsString;
  5.  
but have a need to xfer a Memo field TravelDirections from one table to another.

paweld

  • Hero Member
  • *****
  • Posts: 1061
Code: Pascal  [Select][+][-]
  1. DbfAppmts.FieldByName('MemoFNAME').Value := DbfCntks.FieldByName('MemoFNAME').Value;
Best regards / Pozdrawiam
paweld

egsuh

  • Hero Member
  • *****
  • Posts: 1381
I think AsString will work.

1HuntnMan

  • Full Member
  • ***
  • Posts: 200
  • From Delphi 7 to Lazarus
    • NewFound Photo Art
Thanks, just couldn't find it in my downloaded docs.  I'm adding this to my docs.

I'm going to test both .Value and .String

1HuntnMan

1HuntnMan

  • Full Member
  • ***
  • Posts: 200
  • From Delphi 7 to Lazarus
    • NewFound Photo Art
If you key in:
Code: Pascal  [Select][+][-]
  1.   DbfAppmts.FieldByName('DIRECTIONS').Value:=
  2.      DbfClient.FieldByName('TRAVELDIRECTIONS').Value;
  3.  


Laz will allow when you key . then lookup Value:variant but won't allow .String.

 

TinyPortal © 2005-2018