You are here: Development Standards > Routines > Application-SpecificRoutines > SOAUDPD.PUB

# SOAUDPD.PUB

SOAUDPD.PUB is a public program that handles a variety of functions for period locking functionality. This program is called by RMPERIOD.PUB and GENBATCH.PUB, and handles auditing all files with GL periods in the Sales Order module.

CHECK_BATCH:

This entry point handles checking the SOTHx and ARCRx files when GENBATCH.PUB is ready to post a batch selected by the user.

`1010 CHECK_BATCH:`
`1015 ENTER FILE[ALL],BATCH$`

Variable | Description
FILE[ALL] | Standard file array
BATCH$ | String template used in this procedure

Exit Points | Explanation
EXIT | FILE_CHECK normally exits with no error.

CHECK_PERIOD:

This entry point will check the SOTHx, and ARCRx files for entries in a given period that the user is trying to lock thru the Accounting Periods function in Resource Manager. If Contractors' Job Cost is installed, this procedure will also check the ARJCx, ARJDx, and ARJEx files.

`2005 CHECK_PERIOD:`
`2010 ENTER FILE[ALL],PERIOD$`

Variable | Description
FILE[ALL] | Standard file array
PERIOD$ | String template used in this procedure

DIM_TEMPLATE:

This entry point will dimension the templates used by the other enter points in this routine.

`3010 DIM_TEMPLATE:`
`3020 ENTER BATCH$,PERIOD$`

Variable | Description
BATCH$ | String template used in the CHECK_BATCH enter point
PERIOD$ | String template used in the CHECK_PERIOD enter point

The BATCH$ template has the following format:

Field | Description
BATCH:C(6*) | Current batch ID being posted by GENBATCH.PUB
YEAR:N(1*) | Set to 1 if a batch contains transactions for a locked period
MSG$:C(1*) | Error message returned to calling program

The PERIOD$ template has the following format:

Field | Description
PERIOD:N(1*) | Period to check for transactions in
YEAR:N(1*) | Year to check for transactions in
MSG$:C(1*) | Error message returned to calling program