Skip to main content

#WEBSERVICE

#WEBSERVICE( [FIELDS(fieldlist),][HELP(helptext),][DESCRIPTION(descriptiontext),] );

FIELDSThe FIELDS parameter specifies field sequence in WsECL Web forms. This is an exclusive list. If the FIELDS attribute is present, only the fields in the fieldslist are displayed on the Web form in WsECL.
fieldlistA comma-separated list of field names in the order in which they should appear on the form. Use an asterisk (*) to include unspecified fields.
HELPThe HELP Parameter specifies to add help text to the WsECL Web form.
helptextThe help text to display.
DESCRIPTIONThe DESCRIPTION Parameter specifies to add descriptive text to the WsECL Web form.
descriptiontextThe description text to display.

The #WEBSERVICEstatement sets options for the input parameters on a WsECL Web form for a published query.

Example:

#WEBSERVICE(FIELDS('Field1','AddThem','Field2'),
            HELP('Enter Integer Values'),
            DESCRIPTION('If AddThem is TRUE, this adds the two integers')); 
Field1 := 1 : Stored('Field1');
Field2 := 2 :Stored('Field2');
AddThem := TRUE :STORED ('AddThem');
HiddenValue := 12 :STORED ('HiddenValue'); //not in fieldlist, won't display on WsECl form
IF(AddThem,OUTPUT(Field1+Field2),OUTPUT('Not Added'));

#WEBSERVICE(FIELDS('field1','field2','*'));//includes unspecified fields on the WsECL form

See Also: STORED