Searches the presentation space for the specified field beginning from the index (field number) specified.


Namespace: ScreenUPG
Assembly: ScreenUPG (in ScreenUPG.dll)

Syntax

Visual Basic (Declaration)
Public Function findFieldEx( _ 
   ByVal inBeginIndex As Integer,  _ 
   ByVal inMode As Integer,  _ 
   ByVal inType As Integer,  _ 
   ByVal inWrap As Integer,  _ 
   ByVal outRow As MutableInt,  _ 
   ByVal outColumn As MutableInt,  _ 
   ByVal outLength As MutableInt,  _ 
   ByVal outAttribute As MutableInt _ 
) As Boolean
C#
public bool findFieldEx(
   int inBeginIndex,
   int inMode,
   int inType,
   int inWrap,
   MutableInt outRow,
   MutableInt outColumn,
   MutableInt outLength,
   MutableInt outAttribute
)
C++
public:
 bool findFieldEx(
   int inBeginIndex,
   int inMode,
   int inType,
   int inWrap,
   MutableInt outRow,
   MutableInt outColumn,
   MutableInt outLength,
   MutableInt outAttribute
) sealed 
J#
public bool findFieldEx(
   int inBeginIndex,
   int inMode,
   int inType,
   int inWrap,
   MutableInt outRow,
   MutableInt outColumn,
   MutableInt outLength,
   MutableInt outAttribute
)
JScript
public  function findFieldEx(
   inBeginIndex : int,
   inMode : int,
   inType : int,
   inWrap : int,
   outRow : MutableInt,
   outColumn : MutableInt,
   outLength : MutableInt,
   outAttribute : MutableInt
) : bool

Parameters

inBeginIndex
The index of the field from which to begin searching.
inMode
The field to look for: current, next, or previous (from the specified row and column position). Possible values include FINDFIELD_CURRENT, FINDFIELD_NEXT and FINDFIELD_PREVIOUS.
inType
The type of field to search for. Possible values FIELDTYPE_ANY, FIELDTYPE_PROTECTED and FIELDTYPE_UNPROTECTED.
inWrap
Whether or not to wrap to the top after reaching the end of the presentation space. Possible values include: WRAP_ON and WRAP_OFF.
outRow
The row where the field was found. If the field is not found, the value is set to zero.
outColumn
The column where the field was found. If the field is not found, the value is set to zero.
outLength
The length of the field that was found. If the field is not found, the value is set to zero.
outAttribute
A value representing the field attribute bits of the specified field. See Field Attributes for a list of field attributes returned for each host type.

Return Value

A string containing the specified contents of presentation space. The string includes the requested presentation space positions (characters) as well as the extended character and extended color attributes for each character.

Remarks

If you set inBeginIndex to 1 and set inMode to FINDFIELD_NEXT, it will search for the second field (the next field following field 1). If the specified field is found, the method returns true and the field's boundaries.

Example

[C#]

 Copy Code
            int inBeginIndex = 1;
            int inMode = ScreenUPG.FINDFIELD_NEXT;
            int inType = ScreenUPG.FIELDTYPE_PROTECTED;
            int inWrap = ScreenUPG.WRAP_ON;
            MutableInt outRow = new MutableInt(0);
            MutableInt outColumn = new MutableInt(0);
            MutableInt outLength = new MutableInt(0);
            MutableInt outAttribute = new MutableInt(0);
            
            // Find the next protected field in the presentation space
            boolean found = screen.findFieldEx(inBeginIndex, inMode, inType, inWrap, outRow, outColumn, outLength, outAttribute);
            
[VB]
 Copy Code
            Dim inBeginIndex As Integer
            Dim inStartCol As Integer
            Dim inMode As Integer
            Dim inType As Integer
            Dim inWrap As Integer
            Dim outRow As New Mutable.MutableInt
            Dim outColumn As New Mutable.MutableInt
            Dim outLength As New Mutable.MutableInt
            Dim outAttribute As New Mutable.MutableInt
            Dim found As Boolean
            
            inBeginIndex = 1
            inMode = 1
            inType = 1
            inWrap = 1
            
            'Find the next protected field in the presentation space
            found = screen.findFieldEx(inBeginIndex, inMode, inType, inWrap, outRow, outCol, outLength, outAttribute)
            

See Also