#!/bin/sh # This script is called by ACEDB Pick_me_to_call records. # It copies the file to a temporary file in the current working directory, # and then runs the appropriate viewer. After viewing, the # temporary file is deleted. # $ACE_Viewer is the name of the program. # $1 is the file for the program to use. # RM_CMD - command to be used for removing files and directories if [ -f /usr/bin/rm ] then RM_CMD=/usr/bin/rm else if [ -f /bin/rm ] then RM_CMD=/bin/rm else RM_CMD=rm fi fi #Choose a spreadsheet program if [ -z "$ACE_SPREADSHEET" ] then ACE_SPREADSHEET=scalc fi export ACE_SPREADSHEET echo 'ACE_SPREADSHEET:'$ACE_SPREADSHEET #echo Copying $1 tempfile=acedb_$$ cp $1 ./$tempfile #ls -l ./$tempfile ($ACE_SPREADSHEET $tempfile; $RM_CMD -f $tempfile) &