%I_FLDSIZE
Retrieve an input field’s size
WSupported on Windows
|
USupported on Unix
|
VSupported on OpenVMS
|
NSupported in Synergy .NET
|
size = %I_FLDSIZE(window_id, field_spec)
Return value
size
This function returns the field size as an integer value. (^VAL)
Arguments
window_id
The ID of the input window containing the field. (n)
field_spec
The specification for the field whose size %I_FLDSIZE will retrieve. (See Field specifications for information.) (a)
Discussion
%I_FLDSIZE returns the storage size of the field in bytes. If the field is an array, this is the size of one element.
If either window_id or field_spec is invalid, a fatal error occurs.
This function may be particularly useful as an argument to the L_FINDSPEC subroutine, although it has a variety of uses.
You do not need to declare this function to use it. It is defined in tools.def.
Examples
In this example, the beginning position and length of the find area for the list identified by lstid are determined by the structure position and scope (size * dimension) of the field named in fndfield within the input window identified by inpid. A usual scenario would have inpid identify the input window associated with the list, and the input window set’s structure would also double as the data passed to the list processor.
xcall l_findspec(lstid,, %i_fldstrpos(inpid, fndfield), & %i_fldsize(inpid, fndfield)*%i_flddim(inpid, fndfield))