#!/bin/csh
# This is a program for the example Genesis Tooling Forms.
# This file will exist in form 2.
# The purpose of this program is to run the selected analysis checklist.
# It is called by the "Run Analysis Checklist" button.
# 
# Written by Ian Ticehurst (Autom8 Ltd.)
# Version 1A. Date: 12.09.00 - Initial design and development.
# Version 1B. Date: 11.12.00 - Add source of info. file to support gui creation.
# Version 1C. Date: 05.02.01 - Modify to only check job path if job moved from original location.
#                            - Add save time update to forms.
# Version 1D. Date: 09.02.01 - Modify the setting and useage of $TMP.
# Version 1E. Date: 14.03.01 - Check how "$GENESIS_EDIR" is set to ensure paths are set correctly.
######################################################################### 

source $_genesis_root/sys/scripts/include_me

# Change colour of action button to show action in progress.
set_in_progess genform2 acl

# Close Form
COM close_form,job=$JOB,form=genform2

# Source info.source file and run analysis checklist defined.
source $JOB_PATH/user/info.source
# Open editor on step "pcb".
COM open_entity,job=$JOB,type=step,name=pcb
set group=$COMANS
AUX set_group,group=$group

# Close editor.
COM editor_page_close

COM chklist_open,chklist=$AN_CHK
COM chklist_show,chklist=$AN_CHK
COM chklist_run,chklist=$AN_CHK,nact=a,area=profile
COM chklist_close,chklist=$AN_CHK,mode=hide

# Open Form
COM show_form,job=$JOB,form=genform2

set_complete genform2 acl

save_job

exit 0
