Options

recordreference and fieldreference

Peter99Peter99 Member Posts: 5
edited 2002-11-06 in Navision Attain
I open a recRef and insert a record with fldRef. When I write with
fldRef.VALUE('TEST');
When I write a value in a code field it gets scrambled.

The value becomes 'EST'. The first character disappears.
I tried to put a dummy in front. But when I refer to this field with a filter or a flowfield an error appears. : :x

"A value in the xxx field in the yyy table is too long for the field type. Type: code20"

It looks like there is more inserted in the field then you can see.

Comments

  • Options
    SpeedySpeedy Member Posts: 2
    you have to put the string 'TEST' in a variable

    define: strTest as Text30

    strTest := 'TEST'
    fldRef.VALUE( strTest )

    try it, it will work ... i had the same problem
  • Options
    Peter99Peter99 Member Posts: 5
    A tekst variable does work for the most fields but not for a code field. I realised I had to put the value in a variant. This works. But types like Time, RecordID, BigInteger, Duration and DateTime stil do not work.
Sign In or Register to comment.