GUIDE

Creating Procedures:

STEP 1:-

* Collect all rules governing a procedure
* Write a rough outline of the steps involved
* List the particulars to be furnished at each step

STEP 2:-

* Create the procedure using calpp
* Define the steps
* Define particulars for each step
* Test the procedure by selecting it from proceedings

STEP 3:-

* Write a single script for the procedure
* Fill in all the forms at each step
* Automate the whole proceeding
* Test the procedure by selecting it from proceedings

Naming rules:

Please  note some  of the  variable  names used  in calpp.   Procedure
details   are   given   in    the   array   $proc[].    The   variable
$proc[procedure_name]  gives the  procedure name.   Proceeding details
are  stored in  the  array  $ding[].  Manu  Neethi  Cholan, who  ruled
ancient Tamil  Nadu, had erected  a bell near  his palace, for  use by
citizens  seeking   justice  at  any  hour,  to   initate  a  judicial
proceeding, by sounding the bell.  Thus, the $ding[] array has a past,
and continues to be used in proceedings!  Some other arrays give  past
proceeding information for quick use and reference:

$schcpc[step_code][count][heading][count][particular][count]

$hcpc[heading][count][particular][count]

These multidimensional  arrays are  easy to traverse,  while authoring
scripts to automate form output.

$schcpc is useful and necessary  only for multiple steps.  To traverse
each multiple step:
    while (list ($key, $value)=each($schcpc[step_code])){
	// do something with $value
    }

$hcpc may  normally be  used to create  form output. To  traverse each
heading:
    
    while (list ($k, $v)=each($hcpc[heading])){
	// do something with $value
        // refer to particulars by name: {$v[Name][1]}
    }

The procedure script should give naming rules for proceedings. 
function make_proceeding_name(){
    // code to generate and return a unique proceeding name
    // note: the sequence proceeding_name_seq will return a unique id 
    return $ding_name;
}

The procedure script should also define:
function register_proceeding(){
    // code to register the proceeding
    // this may include creation of table entries in acheads, accounts, ledgers and other tables 
    // examine the sample 
} 
