How to calculate flowfield in RecordRef or FieldRef

Himanshu_SharmaHimanshu_Sharma Member Posts: 2
edited 2013-10-14 in NAV Three Tier
I want to insert flow field data in excel, by using RecordRef and FieldRef variable.
Issue :- Don't know which field is flow field, because RecordRef object can refer to any table in the database.

I use this code to enter data in excel through TABLE.

Name DataType
i Integer
recRef RecordRef
FldRef FieldRef


recRef.OPEN(TableNo); // Open Table

FldRef := recRef.FIELD(array1[1]);
FldRef.SETRANGE(filter);

FOR i := 1 TO recRef.FIELDCOUNT DO BEGIN
FldRef := recRef.FIELDINDEX(i);
EnterCell(RowNo,j,FORMAT(recRef.FIELD(array1[j])),FALSE,FALSE); \\It will print flowfiled as 0 in excel, i want to insert accurate data, but don't know which field is flow field, because "recRef.OPEN(TableNo); " in this line TableNo may be associate with any table.
END;

Comments

  • Luc_VanDyckLuc_VanDyck Member, Moderator, Administrator Posts: 3,633
    Issue :- Don't know which field is flow field, because RecordRef object can refer to any table in the database.
    You can use FldRef.TYPE to find out the data type of a selected field. Then use FldRef.CALCFIELD to have it calculated.
    No support using PM or e-mail - Please use this forum. BC TechDays 2024: 13 & 14 June 2024, Antwerp (Belgium)
Sign In or Register to comment.