Add Object Connection (ADDOBJCNT)

Where allowed to run: All environments (*ALL)
Threadsafe: No
Parameters
Examples
Error messages

The Add Object Connection (ADDOBJCNT) command connects an object to all format or field matching the selection criteria specified by the command. By default, all format or field are selected.

Nota: If many field or format are going to be connected to the object, it is advised to submit this command to a batch job.

Top

Parameters

Keyword Description Choices Notes
OBJ Object Qualified object name Required, Key, Positional 1
Qualifier 1: Object Name, *DDSSRC
Qualifier 2: Collection Name, DEFAULT
TOLEVEL To level *FORMAT, *FIELD, *DDSSRC Required, Key, Positional 2
LNG Language Character value Optional, Key, Positional 3
CMP Company Character value Optional, Key, Positional 4
GRP User group Character value Optional, Key, Positional 5
USR User Character value Optional, Key, Positional 6
LSTCNT List format/field connected *NONE, *, *PRINT, *NOEXE Optional, Key, Positional 7
LIB Library Character value Optional, Key, Positional 8
DSP Display Character value Optional, Key, Positional 9
FMT Format Character value Optional, Key, Positional 10
FLD Field Character value Optional, Key, Positional 11
FMTTYPE Format type Values (up to 4 repetitions): NORMAL, SFL, SFLMSG, SFLCTL, WINDOW Optional, Positional 12
FLDTYPE Field type Values (up to 20 repetitions): A, D, F, I, M, N, S, W, X, Y, E, J, O, G, CONST Optional, Positional 13
FLDTYPECN Field simplified type Char-Num C, N Optional, Positional 14
FLDUSE Field use Values (up to 6 repetitions): I, O, B, H, P, M Optional, Positional 15
FLDLEN Field length Element list Optional, Positional 16
Element 1: From Decimal number,
Element 2: To Decimal number,
FLDDEC Field decimal position Element list Optional, Positional 17
Element 1: From Decimal number,
Element 2: To Decimal number,
FLDTOP Field top position Element list Optional, Positional 18
Element 1: From Decimal number,
Element 2: To Decimal number,
FLDLEFT Field left position Element list Optional, Positional 19
Element 1: From Decimal number,
Element 2: To Decimal number,
REFFLDLIB Reference field library Character value Optional, Positional 20
REFFLDFIL Reference field file Character value Optional, Positional 21
REFFLDFMT Reference field format Character value Optional, Positional 22
REFFLD Reference field Character value Optional, Positional 23
CONSTVALUE 'Constant' %wild%card% text OR Values (up to 100 repetitions): Character value Optional, Positional 24
OPTIND Option indicators connection Values (up to 100 repetitions): Element list Optional, Positional 25
Element 1: Indicator 01, 02, 03, 04, 05, 06, 07, 08, 09, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, N01, N02, N03, N04, N05, N06, N07, N08, N09, N10, N11, N12, N13, N14, N15, N16, N17, N18, N19, N20, N21, N22, N23, N24, N25, N26, N27, N28, N29, N30, N31, N32, N33, N34, N35, N36, N37, N38, N39, N40, N41, N42, N43, N44, N45, N46, N47, N48, N49, N50, N51, N52, N53, N54, N55, N56, N57, N58, N59, N60, N61, N62, N63, N64, N65, N66, N67, N68, N69, N70, N71, N72, N73, N74, N75, N76, N77, N78, N79, N80, N81, N82, N83, N84, N85, N86, N87, N88, N89, N90, N91, N92, N93, N94, N95, N96, N97, N98, N99
Element 2: Indicator 01, 02, 03, 04, 05, 06, 07, 08, 09, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, N01, N02, N03, N04, N05, N06, N07, N08, N09, N10, N11, N12, N13, N14, N15, N16, N17, N18, N19, N20, N21, N22, N23, N24, N25, N26, N27, N28, N29, N30, N31, N32, N33, N34, N35, N36, N37, N38, N39, N40, N41, N42, N43, N44, N45, N46, N47, N48, N49, N50, N51, N52, N53, N54, N55, N56, N57, N58, N59, N60, N61, N62, N63, N64, N65, N66, N67, N68, N69, N70, N71, N72, N73, N74, N75, N76, N77, N78, N79, N80, N81, N82, N83, N84, N85, N86, N87, N88, N89, N90, N91, N92, N93, N94, N95, N96, N97, N98, N99
Element 3: Indicator 01, 02, 03, 04, 05, 06, 07, 08, 09, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, N01, N02, N03, N04, N05, N06, N07, N08, N09, N10, N11, N12, N13, N14, N15, N16, N17, N18, N19, N20, N21, N22, N23, N24, N25, N26, N27, N28, N29, N30, N31, N32, N33, N34, N35, N36, N37, N38, N39, N40, N41, N42, N43, N44, N45, N46, N47, N48, N49, N50, N51, N52, N53, N54, N55, N56, N57, N58, N59, N60, N61, N62, N63, N64, N65, N66, N67, N68, N69, N70, N71, N72, N73, N74, N75, N76, N77, N78, N79, N80, N81, N82, N83, N84, N85, N86, N87, N88, N89, N90, N91, N92, N93, N94, N95, N96, N97, N98, N99
Element 4: Operator AND, OR
CNTTOFLD Connect to this/another field TOTHISFIELD, TOLEFTFIELD, TORIGHTFIELD Optional, Positional 26
UPDCNTXML Update XML connector *YES, *NO Optional, Positional 27
Top

Object (OBJ)

Specifies the object to be connected. An object could be a simple grafical feature, a control or a sofisticated feature with link or image or system-command and reacting to Event such as click, right-click etc...

Nota: To define new OBJECT use the cmd: IWEB/CRTOBJDFN

This is a required parameter.

Qualifier 1: Object

*DDSSRC
*DDSSRC can be used only when the cmd is specified within a DDS source. To specify this cmd within a DDS source you have to use the following format, in completition of the cmd statement CRTOBJDFN:

     A          R FMT1
     A . . .
      *%%IW CRTOBJDFN OBJ(*DDSSRC)
      *%%IW           OBJTYPE(...)
      *%%IW           . . .
      *%%IW ADDOBJCNT OBJ(*DDSSRC)
      *%%IW           TOLEVEL(*DDSSRC)
     A . . .

The parameter value *DDSSRC assume the format or field name preceding the command insertion, like does any DDS keyword.

Nota: To insert the cmd within a DDS source, type-in the cmd in another session, use F14=cmd string and then do a copy/past to the DDS source.

name
Specify the name of the object you want to connect.

Qualifier 2: Collection

DEFAULT
The collection named DEFAULT is used. (Collections are object's containers.)
name
Specify the name of the collection which contain the object you want to connect.

Nota: To define new COLLECTION use the cmd: IWEB/CRTCLC

Top

To level (TOLEVEL)

Specifies the level to which the object will be connected. (record-format or field level)

This is a required parameter.

*FORMAT
The connection will occur at the record-format level.
*FIELD
The connection will occur at the field level.
*DDSSRC
The connection will occur at the DDS source statement level. (This value is valid only if the cmd is inserted within the DDS source)
Top

Language (LNG)

Specifies the language to which the connection will occur. By default all language are included.

character-value
Specify the language ID to which the connection will occur.

Nota: You may promt (F4) this parameter to get a positionable dymanic list.

Top

Company (CMP)

Specifies the company (if your application uses it as a information system) to which the connection will occur. By default all companies are included.

character-value
Specify the company ID to which the connection will occur.

Nota: To add, remove, get or set companies (as information system) use company's commands and session programs.

Nota: You may promt (F4) this parameter to get a positionable dymanic list.

Top

User group (GRP)

Specifies the user-group to which the connection will occur. By default all user-group are included.

character-value
Specify the user-group ID to which the connection will occur.

Nota: You may promt (F4) this parameter to get a positionable dymanic list.

Top

User (USR)

Specifies the user-profil to which the connection will occur. By default all user-profil are included.

character-value
Specify the user-profil ID to which the connection will occur.

Nota: You may promt (F4) this parameter to get a positionable dymanic list.

Top

List format/field connected (LSTCNT)

Specifies if you want to list all format or field resulting connected by the command. You can either display the list or print it.

*NONE
No list of format or field connected is generated.
*
The list of format or field connected is display at the end of the process.
*PRINT
The list of format or field connected is printed at the end of the process.
*NOEXE
The list of format or field potentially connected is displayd and the command is not executed.
Top

Library (LIB)

Specifies the library to which the connection will occur.

This is a required parameter.

character-value
Specify the name of a library.

Nota: You may promt (F4) this parameter to get a positionable dymanic list.

Top

Display (DSP)

Specifies the display name as a selection criteria. By default all display are included.

character-value
Specify the display name. (you can use %wild%card% expression as the LIKE SQL statement does)

Nota: You may promt (F4) this parameter to get a positionable dymanic list.

Top

Format (FMT)

Specifies the format name as a selection criteria. By default all format are included.

character-value
Specify the format name. (you can use %wild%card% expression as the LIKE SQL statement does)

Nota: You may promt (F4) this parameter to get a positionable dymanic list.

Top

Field (FLD)

Specifies the field name as a selection criteria. By default all field are included.

character-value
Specify the field name. (you can use %wild%card% expression as the LIKE SQL statement does)

Nota: You may promt (F4) this parameter to get a positionable dymanic list.

Top

Format type (FMTTYPE)

Specifies the type of record-format as a selection criteria. By default all type of record-format are included.

You can specify 4 values for this parameter.

NORMAL
Only NORMAL record-format type will be selected.
SFL
Only SFL record-format type will be selected.
SFLMSG
Only SFLMSG record-format type will be selected.
SFLCTL
Only SFLCTL record-format type will be selected.
WINDOW
Only WINDOW record-format type will be selected.
Top

Field type (FLDTYPE)

Specifies the type of field as a selection criteria. By default all type of field are included.

You can specify 20 values for this parameter.

A
Alphanumeric shift - Character
D
Digits only - Character or numeric
F
Floating point - Numeric
I
Inhibit keyboard entry - Character or numeric
M
Numeric only character - Character
N
Numeric shift - Character or numeric
S
Signed numeric - Numeric
W
Katakana (for Japan only) - Character
X
Alphabetic only - Character
Y
Numeric only - Numeric
E
DBCS-either field
J
DBCS-only field
O
DBCS-open field
G
DBCS-graphic field
CONST
Constant field
Top

Field simplified type Char-Num (FLDTYPECN)

Specifies the simplified field type (Character or Numeric) as a selection criteria. By default all type of field are included.

C
Character
N
Numeric
Top

Field use (FLDUSE)

Specifies the field usage as a selection criteria. By default all field usage are included.

You can specify 6 values for this parameter.

I
Input field
O
Output field
B
Both usage field
H
Hidden field
P
Program-to-system field
M
Message field
Top

Field length (FLDLEN)

Specifies the length field range as a selection criteria. By default all length field are included.

Element 1: From

From length value
decimal-number
Specify the number of the minimum field length

Element 2: To

To length value
decimal-number
Specify the number of the maximum field length
Top

Field decimal position (FLDDEC)

Specifies the length decimal range as a selection criteria. By default all decimal length are included.

Element 1: From

From length value
decimal-number
Specify the number of the minimun decimal length

Element 2: To

To length value
decimal-number
Specify the number of the maximum decimal length
Top
Top
Top

Reference field library (REFFLDLIB)

Specifies the reference field library name as a selection criteria. By default all reference field library are included.

character-value
Specify the reference field library name (You can use %wild%card% expression as the LIKE SQL statement does)
Top

Reference field display (REFFLDFIL)

Specifies the reference field file name as a selection criteria. By default all reference field file are included.

character-value
Specify the reference field file name (you can use %wild%card% expression as the LIKE SQL statement does)
Top

Reference field format (REFFLDFMT)

Specifies the reference field record-format name as a selection criteria. By default all reference field record-format are included.

character-value
Specify the reference field record-format name (you can use %wild%card% expression as the LIKE SQL statement does)
Top

Reference field (REFFLD)

Specifies the reference field name as a selection criteria. By default all reference field are included.

character-value
Specify the reference field name (you can use %wild%card% expression as the LIKE SQL statement does)
Top

'Constant' %wild%card% text (CONSTVALUE)

Specifies a constant value as a selection criteria. By default all constant are included.

You can specify 100 values for this parameter.

character-value
Specify the constant value (you can use %wild%card% expression as the LIKE SQL statement does)
Top

Option indicators connection (OPTIND)

Specifies option indicators to select a connection at run time. Your program can set option indicators ON or OFF and condition the connection.

Nota: Only original option indicators from the DDS record-format will be controlled by the runtime process of iWeb. If you need extra indicators you may describe them first within your DDS source code, even for dummy field or keyword: (A__12N12___________________________1__2'_')

You can specify 100 values for this parameter.

Element 1: Indicator

01-99
Indicator ON: 01-99, Indicator OFF: N01-N99

Element 2: Indicator

01-99
Indicator ON: 01-99, Indicator OFF: N01-N99

Element 3: Indicator

01-99
Indicator ON: 01-99, Indicator OFF: N01-N99

Element 4: Operator

AND
Operator AND between current list and next list.
OR
Operator OR between current list and next list.
Top

Connect to this or another field (CNTTOFLD)

Specifies to wich field the connection will occur.

TOTHISFIELD
The connection will occur to all fields matching the current selection.
TOLEFTFIELD
The connection will occur to the field placed on the left of all fields matching the current selection.
TORIGHTFIELD
The connection will occur to the field placed on the right of all fields matching the current selection.
Top
Top

Examples for ADDOBJCNT

Example 1: Simple Command Example

ADDOBJCNT OBJ(MYCLC/SLCBUTTON)
          TOLEVEL(*FIELD)
          LIB(MYLIB)
          FLD('ART%')

This command add the object MYCLC/SLCBUTTON (which is a button in this case) to the right of any field having a name starting with "ART" within all display of the library MYLIB

Example 2: Simple Command Example

ADDOBJCNT OBJ(MYCLC/MYIMAGE)
          TOLEVEL(*FORMAT)
          LIB(MYLIB)
          DSP(MYDSP)

This command add the object MYCLC/MYIMAGE (which is an image in this case) to the display MYDSP within the library MYLIB.

Example 3: Simple Command Example

ADDOBJCNT OBJ(MYCLC/MYIMAGE)
          TOLEVEL(*FORMAT)
          LIB(MYLIB)
          DSP(MYDSP)
          FMT(MYSFL)

This command add the object MYCLC/MYIMAGE (which is in this case an image having a variable path, coming from an hidden field within the subfile MYSFL) as a column in the format MYSFL (which is a subfile in this example)

Example 4: More Complex Command Example

ADDOBJCNT OBJ(MYCLC/MYCHECK)
          TOLEVEL(*FIELD)
          LIB(MYLIB)
          FLDLEN(1 1)
          CONSTVALUE('%Y/N%')
          CNTTOFLD(TOLEFTFIELD)

This command transforms any field having a length of 1 in the object MYCLC/MYCHECK (which is a check box in this example) and beeing to the left of any constant with a value like '%Y/N%'.

Top

Error messages

Unknown
Top