I do not have any problem understanding the type of field.

First I have a loop on all formats - the structures called QDFARFTE.
When "inside" the format, I have a loop on all fields - the structure QDFFFINF.
Exact as you say - I go inside this structure and for every field
retrieve some data.

Output from my program for a non-hidden field looks like this:

Field nr. 4
Field name is ZLCLC
Field position is 3 36
Output field
Output buffer displacement is 26
Program length is 3
Field data type is 0

(I was too lazy to "decode" data type, 0 stands for Alpha.)

But with hidden fields (attribute 0x06) field name is filled with
blanks, so to generate a "readable" input I had to make it like this:

if (strlen(rtrim(FldName->WDFFNAM, 10)) > 0)
printf("Field name is %10.10s\n", FldName->WDFFNAM) ;
printf("Field name is <empty>\n", FldName->WDFFNAM) ;

And some hidden field looks like this:

Field nr. 8
Field name is <empty>
Field position is 0 0
Hidden field
Input buffer displacement is 36
Output buffer displacement is 36
Program length is 7
Field data type is 7

This field type is 0x07 that is signed decimal.

However - obviously - hidden fields have names!

On Mon, Aug 18, 2014 at 7:08 PM, Bryan Dietz <bdietz400@xxxxxxxxx> wrote:
First I could not even attempt the coding in "C", but reading the manuals I
searched the following page for "hidden":

Field Header Section (QDFFFINF)

Offset Bit Type Variable Name
Dec Hex

Field attribute. X'01' indicates Constant (see structure QDFFFCON, Constant
Field Header Table (QDFFFCON)), X'02' indicates Output (O), X'03' indicates
Message (M), X'04' indicates Input (I), X'05' indicates Both (B), X'06'
indicates Hidden (H), and X'07' indicates Program to System (P).

Maybe that would help you find the type of field.

Jevgeni Astanovski said the following on Mon, 8/18/2014 9:07 AM:

I used this program as a starting point and successfully retrieved
ALMOST everything.
I needed the following:
Format name, field name, field I/O attribute (Input, Output, Both,
Hidden), field type and field length.
As wrote earlier my failure was with hidden fields.
I found one place where hidden fields names could be retrieved and
another place where I could find (probably) these fields necessary
attributes - but without field names!
Names where available for all but hidden....

On Tue, Aug 12, 2014 at 11:36 PM, Bryan Dietz <bdietz400@xxxxxxxxx> wrote:

I just did a Google search "QDFRTVFD"

which returned a "C" example for the API
"This document contains an example of how to retrieving the Row/Column
of a Field Using the QDFRTVFD API."

This is the Bare Metal Programming IBM i (AS/400 and iSeries) (C400-L)
mailing list
To post a message email: C400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
or email: C400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives

As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2021 by and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.