PECRDCTR: Control the technical sheet response

Use the PECRDCTR entry point to add controls to the technical sheet responses.

Context and operating mode

Transaction
Log file
Call context

The entry point is located just after the standard controls or those defined.

Available variables and masks

ASW variable contains the response. This variable is of "char", "decimal", "date" or "integer" type according to the expected response. 

The instruction "type" is used to recover the type of a variable.  

Open tables

PEQLYA: Addition of action on technical sheet responses

The PEQLYA entry point is used to add actions in the headings of the technical sheet response screen.

According to local menu 31

Context and operating mode

Transaction
Log file
Call context

The entry point is placed just after the standard controls.

Available variables and masks

ASW variable contains the response. This variable is of "char", "decimal", "date" or "integer" type according to the expected response. 

The "type" instruction is used to recover the type of a variable.  

Open tables

PEWRIQLA: Before writing the QLYCRDASW file (Quality - responses records)

Use the PEWRICTR entry point to load specific fields in the QLYCRDASW Quality records - responses file.

Context and operating mode

Transaction

Yes

Log file
Call context

The entry point is located just before the write of the QLYCRDASW recording.

Available variables and masks

Open tables

CALSMPCOD: Calculation of the size and the code of the sample

Use the CALSMPCOD entry point to determine specifically the size and code of the sample.

Context and operating mode

Transaction

There is no transaction in progress. 

Log file
Call context

This entry point is located at the end of the CALSMPCOD component of the CRDLIB processing. 

The CALSMPCOD component calculates the size and code of the sample. 

The EP contains the following elements:

      LTRT integer variable: 1 Automatic determination  

      LQTY decimal variable: Lot initial quantity 

      LCODE char variable: Code of the calculated sampling

      LSMP decimal variable: Sampling size 

      The content of miscellaneous table 103 "Sample size simple plan" is stored in various variables

      of global type.

      Global decimal GNBR103: Number of codes

      Global decimal GQTY103: Initial lot  

      Global integer  GSMP103: Size  

      Global char GCOD103: Code 

Available variables and masks

Open tables

CALACPRM: Calculation of the size of the sample rejection

The CALACPPRM entry point is used to determine specifically the sample rejection size.

Context and operating mode

Transaction

There is no transaction in progress. 

Log file
Call context

This entry point is located at the end of the CALLACPRM component of the CRDLIB processing. 

The CALACPRM component calculates the size of the sample rejection. 

The EP contains the following elements:

      LNQA integer variable: Value of the NQA heading of the ITMFACILIT table  

      LCODE decimal variable: Sample code 

      LCODE char variable: Code of the calculated sampling

      LACP decimal variable: Rejection size 

      The read of the QLYCRDNQA/NQA "Sampling: NQA criteria" table (indus data table) key:  1;LNQA;LCODE determines the size of the rejection      

Open tables

PEQLYARPL: Addition of action for new record

Use the PEQLYARPL entry point to add actions to the new record heading of the technical sheet response screen.

According to local menu 31

Context and operating mode

Transaction
Log file
Call context

The entry point is located just after the standard controls or those defined.

Available variables and masks

ASW variable contains the response. This variable is of "char" type Open tables

QLQGENCRD: Before generating the response entry screen

When generating the quality record, use the QLQGENCRD entry point to modify the content of the work table corresponding to the responses. It is used, for example, to avoid the initialization of the response fields with the default value of the questions.

Context and operating mode

Transaction

Yes

Log file

No

Call context

This entry point is located in the GENCRD sub-program (response entry screen generation) of the CRDLIB processing.

This entry point is placed in the read loop of a technical sheet responses. 

Each response is stored in a table sized by the number of line - 1 of the QLYCRD1/QLY1 screen (Quality record responses) stored in the W_MAX variable.

The components of the table are:

     W_QST: Question

     W_TYP: Response type (local menu no. 252)

     W_CTL: Control type (local menu no. 253)

     W_STD: Miscellaneous response authorized (local menu no. 1)

     W_TCT: Control table

     W_INT: Title

     W_DEF: Default response

     W_LOK: Blocking type (local menu no. 266)

     In standard processing, the loading is as follows:

W_QST (W_I) = [F:QLC]QSTNUM

W_TYP (W_I) = [F:QLQ]DEMASWTYP

W_CTL (W_I) = [F:QLQ]DEMCTLTYP

W_STD (W_I) = [F:QLQ]OSDASW

W_TCT (W_I) = [F:QLQ]TCT

W_LOK (W_I) = [F:QLQ]LOKTYP

W_INT (W_I) = "func CRDLIB.GETQSTSHOAXX('" + [F:QLQ]QSTNUM + "')"

Case [F:QLQ]DEMASWTYP

         When 1: W_DEF (W_I) = '"'+[F:QLQ]ALPDEFASW+'"'

         When 2: W_DEF (W_I) = num$([F:QLQ]NUMDEFASW)

         When 4: W_DEF (W_I) = num$([F:QLQ]NUMDEFASW+1)

         When Default: W_DEF (W_I) = ""

The loading index is stored in the W_I  variable. To modify the value of one of the components

of the table, you must use the value of this index minus 1 (W_I -1), because the index increases by 1 at the end of the loading and before the entry point is called.

Available variables and masks

Open tables

QLYCRD/QLC:  Technical sheet

QLYCRDQST/QLQ: Responses

GEN_ONGLET: Addition of comment field for each question

Use the GEN_ONGLET entry point to add to each question a comment field that can be entered, when generating the technical sheet.

Context and operating mode

Transaction

Yes

Log file

No

Call context

The entry point is located in the GEN_ONGLET sub-program (generation of the response entry screen) of the CRDLIB processing.

The entry point is located in the field creation loop of each response of a technical sheet. 

To add a comment field to each response, the following lines must be written in the entry point:

         GPE = 1                                                                                       

      [F:AMZ2]NOZONE = [F:AMZ1]NOZONE

      For W_I = 0 To W_MAX-1

        If W_QST(W_I) <> ""

          W_NUM  = ((W_J-1)*W_MAX)+(W_I+1)

          W_FLD  = "XXX"+format$("N0:3#",W_NUM)               

          [F:AMZ2]CODZON  = W_FLD

          Write [AMZ2]

          If fstat

            Call FSTA("AMZ2") From GLOCK

            GOK = 0

          Endif

          Gosub COP_PARMSK1 from CRDLIB

          If GOK <> 1

            Break

          Endif

        Endif

        [F:AMZ2]NOZONE += 1

      Next W_I

 

   Properly set the GPE variable to 1.

   "XXX" being the name of the new field

Open tables
QLYCRD/QLC        :  Technical sheet
QLYCRDQST/QLQ: Responses

LECFIC: Read of the specific fields of the QLYCRDASW table

Use the LECFIC entry point to read specific fields of the QLYCRDASW table added by the PEWRIQLA entry point.

Context and operating mode

Transaction

no

Log file

No

Call context

This entry point is located in the LECFIC sub-program (loading sub-program for already entered responses).

The entry point is located in the read loop of the QLYCRDASW table.  

Open tables
QLYCRD/QLC        :  Technical sheet
QLYCRDASW/QLA: Responses